Class: GraphQL::Client::QueryResult::EnumWrapper
- Inherits:
-
Object
- Object
- GraphQL::Client::QueryResult::EnumWrapper
- Defined in:
- lib/graphql/client/query_result.rb
Instance Method Summary collapse
- #cast(value, _errors = nil) ⇒ Object
-
#initialize(type) ⇒ EnumWrapper
constructor
A new instance of EnumWrapper.
- #|(_other) ⇒ Object
Constructor Details
#initialize(type) ⇒ EnumWrapper
Returns a new instance of EnumWrapper.
157 158 159 |
# File 'lib/graphql/client/query_result.rb', line 157 def initialize(type) @type = type end |
Instance Method Details
#cast(value, _errors = nil) ⇒ Object
161 162 163 |
# File 'lib/graphql/client/query_result.rb', line 161 def cast(value, _errors = nil) value end |
#|(_other) ⇒ Object
165 166 167 168 |
# File 'lib/graphql/client/query_result.rb', line 165 def |(_other) # XXX: How would enums merge? self end |