class Ardm::Query::Operator

Constants

ALL
FOR_ARRAY
OPERATORS
ORDERS

Attributes

operator[R]

@api private

target[R]

@api private

Public Class Methods

new(target, operator) click to toggle source

@api private

# File lib/ardm/query/operator.rb, line 57
def initialize(target, operator)
  @target, @operator = target, operator.to_sym
end

Public Instance Methods

for_array() click to toggle source
# File lib/ardm/query/operator.rb, line 46
def for_array
  FOR_ARRAY[operator]
end
inspect() click to toggle source

@api private

# File lib/ardm/query/operator.rb, line 37
def inspect
  "#<#{self.class.name} #{target.inspect}.#{operator.inspect}>"
end
to_arel(relation, value) click to toggle source
# File lib/ardm/query/operator.rb, line 50
def to_arel(relation, value)
  Ardm::Query::Expression.new(relation, target, self, value)
end