Class: Pair
- Inherits:
-
Object
- Object
- Pair
- Defined in:
- lib/libruby/pair.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(value, label) ⇒ Pair
constructor
A new instance of Pair.
Constructor Details
#initialize(value, label) ⇒ Pair
Returns a new instance of Pair.
2 3 4 5 |
# File 'lib/libruby/pair.rb', line 2 def initialize(value, label) @value = value @label = label end |
Instance Attribute Details
#label ⇒ Object
Returns the value of attribute label.
6 7 8 |
# File 'lib/libruby/pair.rb', line 6 def label @label end |
#value ⇒ Object
Returns the value of attribute value.
6 7 8 |
# File 'lib/libruby/pair.rb', line 6 def value @value end |