GraphQLSchema class
The schema against which queries, mutations and subscriptions are executed.
Constructors
-
GraphQLSchema({GraphQLObjectType<
Object?> ? queryType, GraphQLObjectType<Object?> ? mutationType, GraphQLObjectType<Object?> ? subscriptionType, String? description, List<GraphQLNamedType> otherTypes = const [], List<GraphQLDirective> ? directives, SerdeCtx? serdeCtx, SchemaDefinitionNode? astNode, List<SchemaExtensionNode> extensionAstNodes = const []}) - The schema against which queries, mutations and subscriptions are executed.
Properties
-
allTypes
→ List<
GraphQLNamedType> -
Contains all named types in the schema.
Same as
typeMap.values.toList()
.latefinal - astNode → SchemaDefinitionNode?
-
The schema as a
package:gql
parsed nodefinal - description → String?
-
Optional description for the schema
final
-
directiveMap
→ Map<
String, GraphQLDirective> -
A Map from name to
GraphQLDirective
.final -
directives
→ List<
GraphQLDirective> -
Supported directives in this schema.
final
-
extensionAstNodes
→ List<
SchemaExtensionNode> -
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
mutationType
→ GraphQLObjectType<
Object?> ? -
The shape required for any query that changes the state of the server.
final
-
otherTypes
→ List<
GraphQLNamedType> -
Other
GraphQLNamedType
that you want to have in the schemafinal -
queryType
→ GraphQLObjectType<
Object?> ? -
The shape which all queries against the server must take.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- schemaStr → String
-
The schema in Schema Definition Language (SDL) representation
latefinal
- serdeCtx → SerdeCtx
-
Serialization and de-serialization context for GraphQLTypes.
Contains functions for creating objects from serialized values.
final
-
subscriptionType
→ GraphQLObjectType<
Object?> ? -
A GraphQLObjectType describing the form of data sent to
real-time subscribers.
final
-
typeMap
→ Map<
String, GraphQLNamedType> -
A Map from name to GraphQLType.
Contains all named types in the schema.
final
Methods
-
getDirective(
String name) → GraphQLDirective? -
Returns the GraphQLDirective with the given
name
-
getPossibleTypes(
GraphQLCompositeType type) → List< GraphQLObjectType> ? -
Returns all the GraphQLObjectType that implement a given abstract
type
-
getRootType(
OperationType operation) → GraphQLObjectType? -
Returns the type for the given
operation
type -
getType(
String name) → GraphQLNamedType? -
Returns the GraphQLNamedType with the given
name
-
isSubType(
GraphQLCompositeType abstractType, GraphQLObjectType maybeSubType) → bool -
Returns
true
ifmaybeSubType
is a possible type ofabstractType
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
typeElements(
) → Iterable< GraphQLElement> - Returns an iterable over all the type GraphQLElement in the schema.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Properties
- typeNameRegExp → RegExp
-
All GraphQLType names should match this regular expression
final