Class: Query::Node::Key
- Inherits:
-
Query::Node
- Object
- Query::Node
- Query::Node::Key
- Defined in:
- lib/query/node/key.rb
Instance Attribute Summary collapse
-
#key ⇒ Object
Returns the value of attribute key.
Instance Method Summary collapse
- #evaluate(**args) ⇒ Object
-
#initialize(parsed) ⇒ Key
constructor
A new instance of Key.
Constructor Details
#initialize(parsed) ⇒ Key
Returns a new instance of Key.
8 9 10 |
# File 'lib/query/node/key.rb', line 8 def initialize(parsed) self.key = parsed.presence end |
Instance Attribute Details
#key ⇒ Object
Returns the value of attribute key.
6 7 8 |
# File 'lib/query/node/key.rb', line 6 def key @key end |
Instance Method Details
#evaluate(**args) ⇒ Object
12 13 14 |
# File 'lib/query/node/key.rb', line 12 def evaluate(**args) key.to_sym end |