Class: Definition
Instance Attribute Summary collapse
-
#color ⇒ Object
Returns the value of attribute color.
-
#definition ⇒ Object
readonly
Returns the value of attribute definition.
-
#expression ⇒ Object
readonly
Returns the value of attribute expression.
-
#origin ⇒ Object
readonly
Returns the value of attribute origin.
Instance Method Summary collapse
- #<=>(other_def) ⇒ Object
-
#initialize(origin, expression, definition) ⇒ Definition
constructor
A new instance of Definition.
Constructor Details
#initialize(origin, expression, definition) ⇒ Definition
31 32 33 34 35 36 |
# File 'lib/definition.rb', line 31 def initialize(origin, expression, definition) @origin = origin @expression = expression @definition = definition @color = nil end |
Instance Attribute Details
#color ⇒ Object
Returns the value of attribute color.
29 30 31 |
# File 'lib/definition.rb', line 29 def color @color end |
#definition ⇒ Object (readonly)
Returns the value of attribute definition.
28 29 30 |
# File 'lib/definition.rb', line 28 def definition @definition end |
#expression ⇒ Object (readonly)
Returns the value of attribute expression.
28 29 30 |
# File 'lib/definition.rb', line 28 def expression @expression end |
#origin ⇒ Object (readonly)
Returns the value of attribute origin.
28 29 30 |
# File 'lib/definition.rb', line 28 def origin @origin end |
Instance Method Details
#<=>(other_def) ⇒ Object
38 39 40 |
# File 'lib/definition.rb', line 38 def <=>(other_def) return @expression <=> other_def.expression end |