types

package
v0.10.25 Latest Latest
Warning

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

Go to latest
Published: Jan 11, 2024 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Arguments

type Arguments map[string]interface{}

Arguments is a map of values

type Directive

type Directive struct {
	Name      string    `json:"name"`
	Arguments Arguments `json:"arguments,omitempty"`
}

Directive represents an applied directive with arguments

type Directives

type Directives []Directive

Directives is a list of directives

type FragmentDefinition

type FragmentDefinition struct {
	Directives          Directives           `json:"directives,omitempty"`
	TypeCondition       TypeRef              `json:"typeCondition"`
	SelectionSet        Selections           `json:"selectionSet"`
	VariableDefinitions []VariableDefinition `json:"variableDefinitions,omitempty"`
}

FragmentDefinition is a fragment definition from client schema

type Function

type Function struct {
	Name string `json:"name"`
}

Function defines a function name in runtime

type HttpRequest

type HttpRequest struct {
	Headers map[string]string `json:"headers,omitempty"`
}

HttpRequest represents http request data.

type OperationDefinition

type OperationDefinition struct {
	Operation           string               `json:"operation"`
	Name                string               `json:"name"`
	VariableDefinitions []VariableDefinition `json:"variableDefinitions,omitempty"`
	Directives          Directives           `json:"directives,omitempty"`
	SelectionSet        Selections           `json:"selectionSet,omitempty"`
}

OperationDefinition represents operation defined in user schema

type ResponsePath

type ResponsePath struct {
	Prev *ResponsePath `json:"responsePath,omitempty"`
	Key  interface{}   `json:"key"`
}

ResponsePath is a node in response path.

type Selection

type Selection struct {
	Name         string              `json:"name,omitempty"`
	Arguments    Arguments           `json:"arguments,omitempty"`
	Directives   Directives          `json:"directives,omitempty"`
	SelectionSet Selections          `json:"selectionSet,omitempty"`
	Definition   *FragmentDefinition `json:"definition,omitempty"`
}

Selection is a represents a field or fragment requested by client

type Selections

type Selections []Selection

Selections list of selections

type TypeRef

type TypeRef struct {
	Name    string   `json:"name,omitempty"`
	NonNull *TypeRef `json:"nonNull,omitempty"`
	List    *TypeRef `json:"list,omitempty"`
}

TypeRef is a reference to a type defined in schema

type Variable

type Variable struct {
	Name string `json:"name"`
}

Variable is a name of variable defined by client

type VariableDefinition

type VariableDefinition struct {
	Variable     Variable    `json:"variable"`
	DefaultValue interface{} `json:"defaultValue,omitempty"`
}

VariableDefinition client defined variable

Jump to

Keyboard shortcuts

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