Class: GraphQL::Language::Nodes::OperationDefinition

Inherits:
AbstractNode
  • Object
show all
Defined in:
lib/graphql/language/nodes.rb

Overview

A query, mutation or subscription. May be anonymous or named. May be explicitly typed (eg mutation { ... }) or implicitly a query (eg { ... }).

Constant Summary

Constants inherited from AbstractNode

AbstractNode::NO_CHILDREN

Instance Attribute Summary collapse

Attributes inherited from AbstractNode

#filename

Method Summary

Methods inherited from AbstractNode

#==, #children, #children_method_name, children_of_type, #col, #definition_line, #delete_child, inherited, #initialize_copy, #line, #merge, #position, #replace_child, #scalars, #to_query_string

Instance Attribute Details

#operation_typeString?

Returns The root type for this operation, or nil for implicit "query".

Returns:

  • (String, nil)

    The root type for this operation, or nil for implicit "query"



# File 'lib/graphql/language/nodes.rb', line 545

#selectionsArray<Field>

Returns Root-level fields on this operation.

Returns:

  • (Array<Field>)

    Root-level fields on this operation



# File 'lib/graphql/language/nodes.rb', line 542

#variablesArray<VariableDefinition>

Returns Variable $definitions for this operation.

Returns:



# File 'lib/graphql/language/nodes.rb', line 539