Class: QVal
- Inherits:
-
Object
- Object
- QVal
- Defined in:
- lib/qtypes.rb
Overview
parent class for all the quark primitive values
Instance Attribute Summary collapse
-
#val ⇒ Object
Returns the value of attribute val.
Instance Method Summary collapse
- #==(a) ⇒ Object
-
#initialize(v) ⇒ QVal
constructor
A new instance of QVal.
- #to_s ⇒ Object
Constructor Details
#initialize(v) ⇒ QVal
Returns a new instance of QVal.
9 10 11 |
# File 'lib/qtypes.rb', line 9 def initialize(v) @val = v end |
Instance Attribute Details
#val ⇒ Object
Returns the value of attribute val.
7 8 9 |
# File 'lib/qtypes.rb', line 7 def val @val end |
Instance Method Details
#==(a) ⇒ Object
17 18 19 20 |
# File 'lib/qtypes.rb', line 17 def ==(a) return @val == a.val if a.is_a? self.class false end |
#to_s ⇒ Object
13 14 15 |
# File 'lib/qtypes.rb', line 13 def to_s @val.to_s end |