PagedListController<E, S> class

Inheritance

Constructors

PagedListController({int pageSize = 10, int firstPageKey = 0, bool reverse = false, int pageIncrement = 1, int searchPercent = 100, bool forceNewFetch = false})

Properties

config ↔ _PagedListConfig<S>
config is the PagedListController settings
latefinal
error → E?
no setter
firstPageKey int
firstPageKey is the key page, offset or similar to be used in case of a refresh.
final
hasError bool
no setter
hashCode int
The hash code for this object.
no setterinherited
hasListeners bool
Whether any listeners are currently registered.
no setterinherited
isLoading bool
no setter
reverse bool
reverse check if the list is inverted
latefinal
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
searchPercent int
searchPercent is the key to be used in case of a refresh.
final
state List<S>
no setter
value List<S>
The current value stored in this notifier.
getter/setter pairinherited
wasDisposed bool
no setter

Methods

addListener(VoidCallback listener) → void
Register a closure to be called when the object changes.
inherited
clearError({bool update = false}) → void
dispose() → void
Discards any resources used by the object. After this is called, the object is not in a usable state and should be discarded (calls to addListener will throw after the object is disposed).
override
fetchNewItems({required int pageKey}) Future<void>
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notifyListeners() → void
Call all the registered listeners.
inherited
refresh() Future<void>
removeListener(VoidCallback listener) → void
Remove a previously registered closure from the list of closures that are notified when the object changes.
inherited
setError(E value) → void
setListener(Future<List<S>> fetchItems({required int pageKey})) → void
setLoading(bool value, {bool update = true}) → void
toString() String
A string representation of this object.
inherited
update(List<S> state, {dynamic force = false}) → void

Operators

operator ==(Object other) bool
The equality operator.
inherited