Class: Sequel::Postgres::RangeOp
- Inherits:
-
SQL::Wrapper
- Object
- SQL::Expression
- SQL::GenericExpression
- SQL::Wrapper
- Sequel::Postgres::RangeOp
- Defined in:
- lib/sequel/extensions/pg_range_ops.rb
Overview
The RangeOp class is a simple container for a single object that defines methods that yield Sequel expression objects representing PostgreSQL range operators and functions.
Most methods in this class are defined via metaprogramming, see the pg_range_ops extension documentation for details on the API.
Constant Summary collapse
- OPERATORS =
{ :contains => ["(".freeze, " @> ".freeze, ")".freeze].freeze, :contained_by => ["(".freeze, " <@ ".freeze, ")".freeze].freeze, :left_of => ["(".freeze, " << ".freeze, ")".freeze].freeze, :right_of => ["(".freeze, " >> ".freeze, ")".freeze].freeze, :ends_before => ["(".freeze, " &< ".freeze, ")".freeze].freeze, :starts_after => ["(".freeze, " &> ".freeze, ")".freeze].freeze, :adjacent_to => ["(".freeze, " -|- ".freeze, ")".freeze].freeze, :overlaps => ["(".freeze, " && ".freeze, ")".freeze].freeze, }
- FUNCTIONS =
%w'lower upper isempty lower_inc upper_inc lower_inf upper_inf'
Instance Attribute Summary
Attributes inherited from SQL::Wrapper
Instance Method Summary collapse
-
#pg_range ⇒ Object
Return the receiver.
Methods inherited from SQL::Wrapper
Methods included from HStoreOpMethods
Methods included from ArrayOpMethods
Methods included from JSONOpMethods
Methods included from InetOpMethods
Methods included from PGRowOp::ExpressionMethods
Methods included from SQL::SubscriptMethods
Methods included from SQL::StringMethods
Methods included from SQL::PatternMatchMethods
Methods included from SQL::OrderMethods
Methods included from SQL::NumericMethods
Methods included from SQL::ComplexExpressionMethods
#extract, #sql_boolean, #sql_number, #sql_string
Methods included from SQL::CastMethods
#cast, #cast_numeric, #cast_string
Methods included from SQL::BooleanMethods
Methods included from SQL::AliasMethods
Methods inherited from SQL::Expression
#==, attr_reader, #eql?, #hash, inherited, #inspect, #lit, #sql_literal
Constructor Details
This class inherits a constructor from Sequel::SQL::Wrapper
Instance Method Details
#pg_range ⇒ Object
Return the receiver.
91 92 93 |
# File 'lib/sequel/extensions/pg_range_ops.rb', line 91 def pg_range self end |