OfflineOperation<T extends DataModelMixin<T> > class
Represents an offline request that is pending to be retried.
Constructors
-
OfflineOperation({required DataRequestLabel label, required String httpRequest, required int timestamp, Map<
String, String> ? headers, String? body, String? key, _OnSuccessGeneric<T> ? onSuccess, _OnErrorGeneric<T> ? onError, required Adapter<T> adapter})
Properties
-
adapter
→ Adapter<
T> -
final
- body → String?
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
headers
→ Map<
String, String> ? -
final
- httpRequest → String
-
final
- key ↔ String?
-
latefinal
- label → DataRequestLabel
-
final
- method → DataRequestMethod
-
no setter
- model → T?
-
no setter
-
onError
→ _OnErrorGeneric<
T> ? -
final
-
onSuccess
→ _OnSuccessGeneric<
T> ? -
final
-
props
→ List<
Object?> -
The list of properties that will be used to determine whether
two instances are equal.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- stringify → bool
-
If set to
true
, the toString method will be overridden to output this instance's props.no setter - timestamp → int
-
final
- uri → Uri
-
no setter
Methods
-
add(
) → void -
Adds an edge from the
_offlineAdapterKey
to thekey
for save/delete and stores header/param metadata. Also stores callbacks. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
retry(
) → Future< void> -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
remove(
DataRequestLabel label, Adapter< DataModelMixin> adapter) → void -
Removes all edges from the
_offlineAdapterKey
for current metadata, as well as callbacks from memory.