Class: Veritas::Optimizer::Relation::Operation::Binary::RightOrderOperand
- Inherits:
-
Veritas::Optimizer::Relation::Operation::Binary
- Object
- Veritas::Optimizer
- Veritas::Optimizer::Relation::Operation::Binary
- Veritas::Optimizer::Relation::Operation::Binary::RightOrderOperand
- Defined in:
- lib/veritas/optimizer/relation/operation/binary.rb
Overview
Optimize when the right operand is an Order
Constant Summary
Constants inherited from Veritas::Optimizer
Instance Attribute Summary
Attributes included from Function::Binary
Attributes inherited from Veritas::Optimizer
Instance Method Summary collapse
-
#optimizable? ⇒ Boolean
private
Test if the right operand is an Order.
-
#optimize ⇒ Binary
private
Drop the Order and wrap the right operand.
Methods included from Function::Binary
Methods inherited from Veritas::Optimizer
Instance Method Details
#optimizable? ⇒ Boolean
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.
Test if the right operand is an Order
87 88 89 |
# File 'lib/veritas/optimizer/relation/operation/binary.rb', line 87 def optimizable? right.kind_of?(Veritas::Relation::Operation::Order) end |
#optimize ⇒ Binary
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.
Drop the Order and wrap the right operand
96 97 98 |
# File 'lib/veritas/optimizer/relation/operation/binary.rb', line 96 def optimize operation.class.new(left, right.operand) end |