GraphQLResponse<T> class

Inheritance

Constructors

GraphQLResponse({T? body, List<GraphQLError>? graphQLErrors})
GraphQLResponse.fromResponse(Response res)

Properties

body → T?
The decoded body of this Response. You can access the body parameters as Map Ex: body['title'];
finalinherited
bodyBytes Stream<List<int>>?
The response body as a Stream of Bytes.
finalinherited
bodyString String?
The response body as a Stream of Bytes.
finalinherited
graphQLErrors List<GraphQLError>?
final
hasError bool
hasError is true when statusCode is not between 200 and 299.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
headers Map<String, String>?
The response headers.
finalinherited
isOk bool
isOk is true when statusCode is between 200 and 299.
no setterinherited
request Request?
The Http Request linked with this Response.
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
status HttpStatus
HttpStatus from Response. status.connectionError is true when statusCode is null. status.isUnauthorized is true when statusCode is equal 401. status.isNotFound is true when statusCode is equal 404. status.isServerError is true when statusCode is between 500 and 599.
no setterinherited
statusCode int?
The status code returned by the server.
finalinherited
statusText String?
Human-readable context for statusCode.
finalinherited
unauthorized bool
unauthorized is true when statusCode is equal 401.
no setterinherited

Methods

copyWith({Request? request, int? statusCode, Stream<List<int>>? bodyBytes, String? bodyString, String? statusText, Map<String, String>? headers, T? body}) Response<T>
inherited
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