class GraphQL::Language::Nodes::Field

A single selection in a GraphQL query.

Constants

NONE

Public Instance Methods

initialize_node(attributes) click to toggle source

@!attribute selections

@return [Array<Nodes::Field>] Selections on this object (or empty array if this is a scalar field)
# File lib/graphql/language/nodes.rb, line 379
def initialize_node(attributes)
  @name = attributes[:name]
  @arguments = attributes[:arguments] || NONE
  @directives = attributes[:directives] || NONE
  @selections = attributes[:selections] || NONE
  # oops, alias is a keyword:
  @alias = attributes[:alias]
end