Class: GQLi::EnumValue
- Inherits:
-
Object
- Object
- GQLi::EnumValue
- Defined in:
- lib/gqli/enum_value.rb
Overview
Wrapper for Enum values
Instance Attribute Summary collapse
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(value) ⇒ EnumValue
constructor
A new instance of EnumValue.
-
#to_s ⇒ Object
Serializes the enum value to string.
Constructor Details
#initialize(value) ⇒ EnumValue
Returns a new instance of EnumValue.
8 9 10 |
# File 'lib/gqli/enum_value.rb', line 8 def initialize(value) @value = value end |
Instance Attribute Details
#value ⇒ Object (readonly)
Returns the value of attribute value.
6 7 8 |
# File 'lib/gqli/enum_value.rb', line 6 def value @value end |
Instance Method Details
#to_s ⇒ Object
Serializes the enum value to string
13 14 15 |
# File 'lib/gqli/enum_value.rb', line 13 def to_s value.to_s end |