module Mongoid::Matcher::ExpressionOperator
Singleton module provides lookup of logical query operator matchers.
@api private
Constants
- MAP
Public Instance Methods
get(op)
click to toggle source
Returns the matcher module for a given operator.
@param [ String ] op The operator name.
@return [ Module ] The matcher module.
@raises [ Mongoid::Errors::InvalidExpressionOperator
]
Raised if the given operator is unknown.
@api private
# File lib/mongoid/matcher/expression_operator.rb, line 26 def get(op) MAP.fetch(op) rescue KeyError raise Errors::InvalidExpressionOperator.new(op) end