Contents

init(fetchDescriptor:sectionBy:modelContext:isolation:)

Creates a new observer with the given fetch descriptor, a String section key path, and a model context.

Declaration

convenience init(fetchDescriptor: FetchDescriptor<Element> = FetchDescriptor<Element>(), sectionBy: KeyPath<Element, String>, modelContext: ModelContext, isolation: isolated (any Actor)? = #isolation) throws

Parameters

  • fetchDescriptor:

    The descriptor defining the fetch criteria.

  • sectionBy:

    A key path on the element type that returns the section name.

  • modelContext:

    The model context to fetch from and observe for changes.

Discussion

See Also

Creating a results observer with a fetch descriptor