query

package
v0.0.0-...-52080e1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 17, 2017 License: BSD-2-Clause Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Query        OperationType = "QUERY"
	Mutation                   = "MUTATION"
	Subscription               = "SUBSCRIPTION"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Document

type Document struct {
	Operations OperationList
	Fragments  FragmentList
}

func Parse

func Parse(queryString string) (*Document, *errors.QueryError)

type Field

type Field struct {
	Alias           common.Ident
	Name            common.Ident
	Arguments       common.ArgumentList
	Directives      common.DirectiveList
	Selections      []Selection
	SelectionSetLoc errors.Location
}

type Fragment

type Fragment struct {
	On         common.TypeName
	Selections []Selection
}

type FragmentDecl

type FragmentDecl struct {
	Fragment
	Name       common.Ident
	Directives common.DirectiveList
	Loc        errors.Location
}

type FragmentList

type FragmentList []*FragmentDecl

func (FragmentList) Get

func (l FragmentList) Get(name string) *FragmentDecl

type FragmentSpread

type FragmentSpread struct {
	Name       common.Ident
	Directives common.DirectiveList
	Loc        errors.Location
}

type InlineFragment

type InlineFragment struct {
	Fragment
	Directives common.DirectiveList
	Loc        errors.Location
}

type Operation

type Operation struct {
	Type       OperationType
	Name       common.Ident
	Vars       common.InputValueList
	Selections []Selection
	Directives common.DirectiveList
	Loc        errors.Location
}

type OperationList

type OperationList []*Operation

func (OperationList) Get

func (l OperationList) Get(name string) *Operation

type OperationType

type OperationType string

type Selection

type Selection interface {
	// contains filtered or unexported methods
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL