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

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

Instance Attribute Summary collapse

Attributes inherited from AbstractNode

#col, #line

Instance Method Summary collapse

Methods inherited from AbstractNode

child_attributes, #children, #initialize, #position, #to_query_string

Constructor Details

This class inherits a constructor from GraphQL::Language::Nodes::AbstractNode

Instance Attribute Details

#directivesObject

Returns the value of attribute directives.



178
179
180
# File 'lib/graphql/language/nodes.rb', line 178

def directives
  @directives
end

#nameObject

Returns the value of attribute name.



178
179
180
# File 'lib/graphql/language/nodes.rb', line 178

def name
  @name
end

#operation_typeObject

Returns the value of attribute operation_type.



178
179
180
# File 'lib/graphql/language/nodes.rb', line 178

def operation_type
  @operation_type
end

#selectionsObject

Returns the value of attribute selections.



178
179
180
# File 'lib/graphql/language/nodes.rb', line 178

def selections
  @selections
end

#variablesObject

Returns the value of attribute variables.



178
179
180
# File 'lib/graphql/language/nodes.rb', line 178

def variables
  @variables
end

Instance Method Details

#initialize_node(operation_type: nil, name: nil, variables: [], directives: [], selections: []) ⇒ Object



181
182
183
184
185
186
187
# File 'lib/graphql/language/nodes.rb', line 181

def initialize_node(operation_type: nil, name: nil, variables: [], directives: [], selections: [])
  @operation_type = operation_type
  @name = name
  @variables = variables
  @directives = directives
  @selections = selections
end