Class: GraphQL::Language::Nodes::Argument
- Inherits:
-
AbstractNode
- Object
- AbstractNode
- GraphQL::Language::Nodes::Argument
- Defined in:
- lib/graphql/language/nodes.rb
Overview
A key-value pair for a field's inputs
Constant Summary
Constants inherited from AbstractNode
GraphQL::Language::Nodes::AbstractNode::NO_CHILDREN
Instance Attribute Summary collapse
-
#name ⇒ String
The key for this argument.
-
#value ⇒ String, ...
The value passed for this key.
Attributes inherited from AbstractNode
Instance Method Summary collapse
Methods inherited from AbstractNode
#==, #children_method_name, children_of_type, #delete_child, inherited, #initialize, #initialize_copy, #merge, #position, #replace_child, #scalars, #to_query_string
Constructor Details
This class inherits a constructor from GraphQL::Language::Nodes::AbstractNode
Instance Attribute Details
#name ⇒ String
Returns the key for this argument.
|
# File 'lib/graphql/language/nodes.rb', line 319
|
#value ⇒ String, ...
Returns The value passed for this key.
325 326 327 |
# File 'lib/graphql/language/nodes.rb', line 325 def children @children ||= Array(value).flatten.tap { _1.select! { |v| v.is_a?(AbstractNode) } } end |
Instance Method Details
#children ⇒ Object
325 326 327 |
# File 'lib/graphql/language/nodes.rb', line 325 def children @children ||= Array(value).flatten.tap { _1.select! { |v| v.is_a?(AbstractNode) } } end |