Class: Oedipus::Comparison::Outside
- Inherits:
-
Oedipus::Comparison
- Object
- Oedipus::Comparison
- Oedipus::Comparison::Outside
- Defined in:
- lib/oedipus/comparison/outside.rb
Overview
Outside comparison of range.
Instance Attribute Summary
Attributes inherited from Oedipus::Comparison
Instance Method Summary collapse
Methods inherited from Oedipus::Comparison
#==, #initialize, of
Constructor Details
This class inherits a constructor from Oedipus::Comparison
Instance Method Details
#inverse ⇒ Object
17 18 19 |
# File 'lib/oedipus/comparison/outside.rb', line 17 def inverse Comparison::Between.new(v) end |
#to_sql ⇒ Object
13 14 15 |
# File 'lib/oedipus/comparison/outside.rb', line 13 def to_sql ["NOT BETWEEN ? AND ?", v.first, v.exclude_end? ? v.end - 1 : v.end] end |