GraphQLSchema class

/ A GraphQL Schema definition without field resolution capacities.

A schemahttps://spec.graphql.org/draft/#sec-Schema) represents a GraphQL service’s collective type system capabilities.

A schema is defined in terms of the types and directives it supports as well as the root operation types for each kind of operation (OperationTypeDefinition): query, mutation, and subscription; this determines the place in the type system where those operations begin.

Inheritance
Annotations
  • @immutable

Constructors

GraphQLSchema(SchemaDefinitionNode? astNode, {DocumentNode? fullDocumentAst, Map<String?, TypeDefinition?>? typeMap, List<DirectiveDefinition>? directives})
const

Properties

astNode → SchemaDefinitionNode?
The underlying definition node from gql/ast.dart
final
directives → List<DirectiveDefinition>?
final
enums → List<EnumTypeDefinition>
no setter
fullDocumentAst → DocumentNode?
final
hashCode → int
The hash code for this object.
no setterinherited
inputObjectTypes → List<InputObjectTypeDefinition>
no setter
interaces → List<InterfaceTypeDefinition>
no setter
mutation → ObjectTypeDefinition?
no setter
name → String?
no setteroverride
objectTypes → List<ObjectTypeDefinition>
no setter
operationTypes → List<OperationTypeDefinition>
no setter
query → ObjectTypeDefinition?
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
subscription → ObjectTypeDefinition?
no setter
typeMap → Map<String?, TypeDefinition?>
Map of all type names to their respective TypeDefinitions, with type resolution enabled (if applicable)
no setter
unions → List<UnionTypeDefinition>
no setter

Methods

getDirective(String name) → DirectiveDefinition?
Definition for the given directive name, if any exists
getPossibleTypes(AbstractType? abstractType) → List<ObjectTypeDefinition>
Get the possible ObjectTypeDefinitions that the given abstractType could be resolved into
getType(String name) → TypeDefinition?
Resolve the given name into a TypeDefinition defined within the schema
isSubType(AbstractType abstractType, ObjectTypeDefinition objectType) → bool
Determine whether objectType is a acceptable as the given abstractType
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.
inherited

Static Methods

fromNode(DocumentNode documentNode) → GraphQLSchema
Build a schema from documentNode