Class: GraphQL::Language::Nodes::InputObjectTypeDefinition

Inherits:
AbstractNode
  • Object
show all
Includes:
Scalars::Name
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

#descriptionObject

Returns the value of attribute description.



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

def description
  @description
end

#directivesObject

Returns the value of attribute directives.



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

def directives
  @directives
end

#fieldsObject

Returns the value of attribute fields.



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

def fields
  @fields
end

#nameObject

Returns the value of attribute name.



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

def name
  @name
end

Instance Method Details

#childrenObject



550
551
552
# File 'lib/graphql/language/nodes.rb', line 550

def children
  fields + directives
end

#initialize_node(name:, fields:, directives: [], description: nil) ⇒ Object



543
544
545
546
547
548
# File 'lib/graphql/language/nodes.rb', line 543

def initialize_node(name:, fields:, directives: [], description: nil)
  @name = name
  @fields = fields
  @directives = directives
  @description = description
end