Module: Mongoid::Matcher::ExpressionOperator Private

Defined in:
build/mongoid-7.3/lib/mongoid/matcher/expression_operator.rb

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

Constant Summary collapse

MAP =

This constant is part of a private API. You should avoid using this constant if possible, as it may be removed or be changed in the future.

{
  '$and' => And,
  '$nor' => Nor,
  '$or' => Or,
}.freeze

Class Method Summary collapse

Class Method Details

.get(op) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



12
13
14
15
16
# File 'build/mongoid-7.3/lib/mongoid/matcher/expression_operator.rb', line 12

module_function def get(op)
  MAP.fetch(op)
rescue KeyError
  raise Errors::InvalidExpressionOperator.new(op)
end