Class: GraphQL::Language::Nodes::UnionTypeExtension

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

Instance Attribute Summary collapse

Attributes inherited from AbstractNode

#col, #filename, #line

Instance Method Summary collapse

Methods inherited from AbstractNode

#eql?, #initialize, #position, #scalars, #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



565
566
567
# File 'lib/graphql/language/nodes.rb', line 565

def directives
  @directives
end

#nameObject

Returns the value of attribute name



565
566
567
# File 'lib/graphql/language/nodes.rb', line 565

def name
  @name
end

#typesObject

Returns the value of attribute types



565
566
567
# File 'lib/graphql/language/nodes.rb', line 565

def types
  @types
end

Instance Method Details

#childrenObject



573
574
575
# File 'lib/graphql/language/nodes.rb', line 573

def children
  types + directives
end

#initialize_node(name:, types:, directives: []) ⇒ Object



567
568
569
570
571
# File 'lib/graphql/language/nodes.rb', line 567

def initialize_node(name:, types:, directives: [])
  @name = name
  @types = types
  @directives = directives
end