Class: Tequila::Node::Static
- Inherits:
-
Object
- Object
- Tequila::Node::Static
- Defined in:
- lib/tree.rb
Instance Attribute Summary collapse
-
#label ⇒ Object
Returns the value of attribute label.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
-
#initialize(label, value) ⇒ Static
constructor
A new instance of Static.
- #to_s ⇒ Object
Constructor Details
#initialize(label, value) ⇒ Static
Returns a new instance of Static.
167 168 169 170 |
# File 'lib/tree.rb', line 167 def initialize label, value @label = label @value = value end |
Instance Attribute Details
#label ⇒ Object
Returns the value of attribute label.
164 165 166 |
# File 'lib/tree.rb', line 164 def label @label end |
#value ⇒ Object
Returns the value of attribute value.
165 166 167 |
# File 'lib/tree.rb', line 165 def value @value end |
Instance Method Details
#to_s ⇒ Object
172 173 174 |
# File 'lib/tree.rb', line 172 def to_s "#{label}: #{value}" end |