QueryResult class

A single operation result

Constructors

QueryResult({Map<String, dynamic> data, OperationException exception, Context context = const Context(), @required QueryResultSource source})
QueryResult.loading({Map<String, dynamic> data})
factory
QueryResult.optimistic({Map<String, dynamic> data})
factory

Properties

context Context
Response context. Defaults to an empty Context()
read / write
data Map<String, dynamic>
Response data
read / write
exception OperationException
read / write
hasException bool
Whether the response includes an exception
read-only
hashCode int
The hash code for this object. [...]
read-only, inherited
isConcrete bool
data has been specified and is not an QueryResultSource.optimisticResult [...]
read-only
isLoading bool
data has yet to be specified from any source for the most recent operation (including QueryResultSource.optimisticResult) [...]
read-only
isNotLoading bool
data been specified (including QueryResultSource.optimisticResult)
read-only
isOptimistic bool
data has been specified as an QueryResultSource.optimisticResult [...]
read-only
loading bool
data been specified (including QueryResultSource.optimisticResult)
@Deprecated('Use `isLoading` instead. Will be removed in 5.0.0'), read-only
optimistic bool
data has been specified as an QueryResultSource.optimisticResult [...]
@Deprecated('Use `isOptimistic` instead. Will be removed in 5.0.0'), read-only
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
source QueryResultSource
The source of the result data. [...]
read / write
timestamp DateTime
read / write

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
toString() String
A string representation of this object. [...]
override

Operators

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

Static Properties

unexecuted QueryResult
Unexecuted singleton, used as a placeholder for mutations, etc.
final