Class: GraphQL::EnumType::EnumValue
- Inherits:
-
Object
- Object
- GraphQL::EnumType::EnumValue
- Includes:
- Define::InstanceDefinable
- Defined in:
- lib/graphql/enum_type.rb
Overview
A value within an GraphQL::EnumType
Created with the value
helper
Constant Summary collapse
- ATTRIBUTES =
[:name, :description, :deprecation_reason, :value]
Instance Attribute Summary collapse
-
#ast_node ⇒ Object
Returns the value of attribute ast_node.
Instance Method Summary collapse
Methods included from Define::InstanceDefinable
#define, #initialize_copy, #metadata, #redefine
Instance Attribute Details
#ast_node ⇒ Object
Returns the value of attribute ast_node.
141 142 143 |
# File 'lib/graphql/enum_type.rb', line 141 def ast_node @ast_node end |
Instance Method Details
#graphql_name ⇒ Object
151 152 153 |
# File 'lib/graphql/enum_type.rb', line 151 def graphql_name name end |
#name=(new_name) ⇒ Object
145 146 147 148 149 |
# File 'lib/graphql/enum_type.rb', line 145 def name=(new_name) # Validate that the name is correct GraphQL::NameValidator.validate!(new_name) @name = new_name end |