Class: VORuby::ADQL::Comparison
- Defined in:
- lib/voruby/adql/adql.rb,
lib/voruby/adql/transforms.rb
Overview
The comparison operators such as Less-than or More-than, etc.
Constant Summary collapse
- @@values =
['=', '<>', '>', '>=', '<', '<=']
Instance Attribute Summary collapse
-
#value ⇒ Object
Returns the value of attribute value.
-
#values_list ⇒ Object
readonly
Returns the value of attribute values_list.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(value, values_list = nil) ⇒ Comparison
constructor
A new instance of Comparison.
- #to_adqls ⇒ Object
- #to_adqlx ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize(value, values_list = nil) ⇒ Comparison
Returns a new instance of Comparison.
778 779 780 781 |
# File 'lib/voruby/adql/adql.rb', line 778 def initialize(value, values_list=nil) @values_list = values_list || @@values self.value = value end |
Instance Attribute Details
#value ⇒ Object
Returns the value of attribute value.
774 775 776 |
# File 'lib/voruby/adql/adql.rb', line 774 def value @value end |
#values_list ⇒ Object (readonly)
Returns the value of attribute values_list.
774 775 776 |
# File 'lib/voruby/adql/adql.rb', line 774 def values_list @values_list end |
Class Method Details
.from_xml(node) ⇒ Object
796 797 798 |
# File 'lib/voruby/adql/adql.rb', line 796 def self.from_xml(node) return Comparison.new(node.attributes['Comparison']) end |
Instance Method Details
#to_adqls ⇒ Object
173 174 175 |
# File 'lib/voruby/adql/transforms.rb', line 173 def to_adqls self.value end |
#to_adqlx ⇒ Object
177 178 179 |
# File 'lib/voruby/adql/transforms.rb', line 177 def to_adqlx self.value end |
#to_s ⇒ Object
792 793 794 |
# File 'lib/voruby/adql/adql.rb', line 792 def to_s "{value=#{self.value}}" end |