BoxerLoader<T> class
Constructors
- BoxerLoader({required void howToUpdateCache(T value), required void howToUpdateView(T value, bool isFromCache), BoxerLoadErrorCallback? onLoadError})
Properties
- enableCache ↔ bool
-
Whether to enable the cache feature
getter/setter pair
- hashCode → int
-
The hash code for this object.
no setterinherited
- howToUpdateCache ↔ void Function(T value)
-
getter/setter pair
- howToUpdateView ↔ void Function(T value, bool isFromCache)
-
getter/setter pair
- isEnableCache → bool
-
no setter
- onLoadError ↔ BoxerLoadErrorCallback?
-
Instance Error callback for
requestFutureandcacheFuturegetter/setter pair - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
getData(
{required Future< T> ? loadCacheFuture, required Future<T> ? loadRequestFuture, BoxerLoadErrorCallback? onLoadError}) → Future<T?> -
Unless
loadRequestFutureis completed beforeloadCacheFuture, bothloadRequestFutureandloadCacheFuturewill call howToUpdateView to update the view -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
update(
T value, {bool isValueFromCache = false, bool isOnlyUpdateView = false}) → void
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited