OperationResponse<TData, TVars> class

Encapsulates a GraphQL operation's response, with typed input and responses, and errors.

Annotations
  • @immutable

Constructors

OperationResponse({required OperationRequest<TData, TVars> operationRequest, DataSource dataSource = DataSource.None, TData? data, dynamic extensions, List<GraphQLError>? graphqlErrors, LinkException? linkException})
Instantiates a GraphQL response.
const

Properties

data → TData?
The typed data of this response.
final
dataSource DataSource
The origin of the response.
final
extensions → dynamic
Extension data returned with the response
final
graphqlErrors List<GraphQLError>?
The list of errors in this response.
final
hasErrors bool
If this response has any error.
no setter
hashCode int
The hash code for this object.
no setteroverride
linkException → LinkException?
Any error returned by Link
final
loading bool
no setter
operationRequest OperationRequest<TData, TVars>
The event that resulted in this response
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

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 o) bool
The equality operator.
override