RemoterData<T> class

Represents data fetched for RemoterQuery T represents the type of data fetched in the query

Inheritance

Constructors

RemoterData({required String key, required T? data, DateTime? updatedAt, Object? error, RemoterStatus? status, bool? isRefetching, int? failCount})
Represents data fetched for RemoterQuery T represents the type of data fetched in the query

Properties

data → T?
Represents data execute function returns on RemoterStatus.success
final
error Object?
Represents error object if status is RemoterStatus.error also can be non-null if next or previous page fetch fails
getter/setter pairinherited
failCount int
Represents how many times execute function failed while fetching this query, default 0
finalinherited
hashCode int
The hash code for this object.
no setterinherited
isRefetching bool
True if query refetch is in progress, default false
getter/setter pairinherited
key String
Unique identifier of data
getter/setter pairinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
status RemoterStatus
Represents state of data, default RemoterStatus.idle
getter/setter pairinherited
updatedAt DateTime
Represents last time data is updated, default now
getter/setter pairinherited

Methods

copyWith({String? key, Nullable<T>? data, Nullable<Object>? error, Nullable<DateTime>? updatedAt, Nullable<RemoterStatus>? status, Nullable<bool>? isRefetching, Nullable<int>? failCount}) RemoterData<T>
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

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