Query<Data, Err> class
Properties
- encodedKey → String
-
no setterinherited
- hasGcTimer → bool
-
no setterinherited
- hashCode → int
-
The hash code for this object.
no setterinherited
- hasListener → bool
-
no setterinherited
- hasRefetchTimer → bool
-
no setterinherited
- isStale → bool
-
no setterinherited
- key → FueryKey
-
no setterinherited
- options → QueryOptions
-
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- shouldSkipFetch → bool
-
no setterinherited
-
stream
→ ValueStream<
QueryState< Data, Err> > -
Returns stream of state and Assign
BehaviorSubjectif not exists.no setterinherited
Methods
-
cancelGcTimer(
) → void -
Cancel timer if timer exists.
inherited
-
cancelRefetchTimer(
) → void -
Cancel timer if timer exists.
inherited
-
emit(
QueryState< Data, Err> state) → void -
Updates the state to the provided
state.inherited -
fetch(
) → void - Called when an new Query created.
-
invalidate(
) → void - invalidate Query.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
refetch(
) → void - Refresh query.
-
setGcTimer(
{required int gcTime, required void callback()}) → void -
Set timer if timer is null.
inherited
-
setRefetchTimer(
{required int interval, required void callback()}) → void -
Set timer if timer is null.
inherited
-
sleep(
) → Future< void> -
Close
BehaviorSubjectand start the garbage collector timer.inherited -
toString(
) → String -
A string representation of this object.
inherited
-
updateOptions(
QueryOptions options) → void -
Updates options to the provided
options.inherited -
wake(
) → void -
Assign a
BehaviorSubject, indicating that listeners can subscribe to it.inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
use<
Data, Err> ({required QueryKey queryKey, required QueryFn< Data> queryFn, int? gcTime, int? staleTime, int? refetchInterval, Data? initialData}) → QueryResult<Data, Err> - Returns QueryResult new or existing Query.