FUIDataLoader
open class FUIDataLoader<Entity> : ObservableObject where Entity : Identifiable
The generic-typed FUIDataLoader
creates data queries on demand for a FUIListViewModel
.
-
Provides list of updated results after execution of a data query
Declaration
Swift
@Published public var results: [Entity] { get set }
-
Provides error when executing a data query
Declaration
Swift
@Published public var error: Error? { get set }
-
Creates a data query.
Declaration
Swift
open func query(forItemsIn range: Range<Int>? = nil, with searchString: String? = nil)
Parameters
forItemsIn
Optional range of entity items that will be returned from the query.
with
Optional search string that will be used to create a search query.