graphql-0.11.1.0: Haskell GraphQL implementation
Safe HaskellNone
LanguageHaskell2010

Language.GraphQL.Type.Schema

Description

This module provides a representation of a GraphQL Schema in addition to functions for defining and manipulating schemas.

Synopsis

Documentation

schema Source #

Arguments

:: forall m. ObjectType m

Query type.

-> Maybe (ObjectType m)

Mutation type.

-> Maybe (ObjectType m)

Subscription type.

-> Directives

Directive definitions.

-> Schema m

Schema.

Schema constructor.

data Schema m Source #

A Schema is created by supplying the root types of each type of operation, query and mutation (optional). A schema definition is then supplied to the validator and executor.

Note: When the schema is constructed, by default only the types that are reachable by traversing the root types are included, other types must be explicitly referenced.

type Directives = HashMap Name Directive Source #

Directive definitions.

data Directive Source #

Directive definition.

data Type m Source #

These are all of the possible kinds of types.

Instances

Instances details
Eq (Type m) Source # 
Instance details

Defined in Language.GraphQL.Type.Internal

Methods

(==) :: Type m -> Type m -> Bool #

(/=) :: Type m -> Type m -> Bool #

query :: forall m. Schema m -> ObjectType m Source #

Schema query type.

mutation :: forall m. Schema m -> Maybe (ObjectType m) Source #

Schema mutation type.

subscription :: forall m. Schema m -> Maybe (ObjectType m) Source #

Schema subscription type.

directives :: forall m. Schema m -> Directives Source #

Schema directive definitions.

types :: forall m. Schema m -> HashMap Name (Type m) Source #

Types referenced by the schema.

implementations :: forall m. Schema m -> HashMap Name [Type m] Source #

Interface implementations.