Class: Logicality::Parser::Ast::ValueOperandNode
- Defined in:
- lib/logicality/parser/ast/value_operand_node.rb
Overview
A value operand node is a node with no children but holds a value instead.
Instance Attribute Summary collapse
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Attributes inherited from Node
Instance Method Summary collapse
-
#initialize(token) ⇒ ValueOperandNode
constructor
A new instance of ValueOperandNode.
Methods inherited from Node
Constructor Details
#initialize(token) ⇒ ValueOperandNode
Returns a new instance of ValueOperandNode.
17 18 19 20 21 22 |
# File 'lib/logicality/parser/ast/value_operand_node.rb', line 17 def initialize(token) super(token) @name = 'value_operand_node' @value = token.value end |
Instance Attribute Details
#value ⇒ Object (readonly)
Returns the value of attribute value.
15 16 17 |
# File 'lib/logicality/parser/ast/value_operand_node.rb', line 15 def value @value end |