Package org.apache.calcite.rex
Class LogicVisitor
java.lang.Object
org.apache.calcite.rex.RexBiVisitorImpl<R,R>
org.apache.calcite.rex.RexUnaryBiVisitor<@Nullable RelOptUtil.Logic>
org.apache.calcite.rex.LogicVisitor
- All Implemented Interfaces:
RexBiVisitor<RelOptUtil.Logic,
RelOptUtil.Logic>
Visitor pattern for traversing a tree of
RexNode
objects.-
Field Summary
Fields inherited from class org.apache.calcite.rex.RexBiVisitorImpl
deep
-
Method Summary
Modifier and TypeMethodDescriptionstatic void
collect
(RexNode node, RexNode seek, RelOptUtil.Logic logic, List<RelOptUtil.Logic> logicList) protected @Nullable RelOptUtil.Logic
end
(RexNode node, @Nullable RelOptUtil.Logic arg) Called as the last action of, and providing the result for, eachvisitXxx
method; derived classes may override.static RelOptUtil.Logic
find
(RelOptUtil.Logic logic, List<RexNode> nodes, RexNode seek) Finds a suitable logic for evaluatingseek
within a list of expressions.@Nullable RelOptUtil.Logic
visitCall
(RexCall call, @Nullable RelOptUtil.Logic logic) @Nullable RelOptUtil.Logic
visitFieldAccess
(RexFieldAccess fieldAccess, @Nullable RelOptUtil.Logic arg) @Nullable RelOptUtil.Logic
visitOver
(RexOver over, @Nullable RelOptUtil.Logic arg) @Nullable RelOptUtil.Logic
visitSubQuery
(RexSubQuery subQuery, @Nullable RelOptUtil.Logic arg) Methods inherited from class org.apache.calcite.rex.RexUnaryBiVisitor
visitCorrelVariable, visitDynamicParam, visitInputRef, visitLiteral, visitLocalRef, visitPatternFieldRef, visitRangeRef, visitTableInputRef
Methods inherited from class org.apache.calcite.rex.RexBiVisitorImpl
visitLambda
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.apache.calcite.rex.RexBiVisitor
visitEach, visitEachIndexed, visitList, visitList
-
Method Details
-
find
Finds a suitable logic for evaluatingseek
within a list of expressions.Chooses a logic that is safe (that is, gives the right answer) with the fewest possibilities (that is, we prefer one that returns [true as true, false as false, unknown as false] over one that distinguishes false from unknown).
-
collect
public static void collect(RexNode node, RexNode seek, RelOptUtil.Logic logic, List<RelOptUtil.Logic> logicList) -
visitCall
- Specified by:
visitCall
in interfaceRexBiVisitor<RelOptUtil.Logic,
RelOptUtil.Logic> - Overrides:
visitCall
in classRexUnaryBiVisitor<@Nullable RelOptUtil.Logic>
-
end
Description copied from class:RexUnaryBiVisitor
Called as the last action of, and providing the result for, eachvisitXxx
method; derived classes may override.- Overrides:
end
in classRexUnaryBiVisitor<@Nullable RelOptUtil.Logic>
-
visitOver
- Specified by:
visitOver
in interfaceRexBiVisitor<RelOptUtil.Logic,
RelOptUtil.Logic> - Overrides:
visitOver
in classRexUnaryBiVisitor<@Nullable RelOptUtil.Logic>
-
visitFieldAccess
public @Nullable RelOptUtil.Logic visitFieldAccess(RexFieldAccess fieldAccess, @Nullable RelOptUtil.Logic arg) - Specified by:
visitFieldAccess
in interfaceRexBiVisitor<RelOptUtil.Logic,
RelOptUtil.Logic> - Overrides:
visitFieldAccess
in classRexUnaryBiVisitor<@Nullable RelOptUtil.Logic>
-
visitSubQuery
public @Nullable RelOptUtil.Logic visitSubQuery(RexSubQuery subQuery, @Nullable RelOptUtil.Logic arg) - Specified by:
visitSubQuery
in interfaceRexBiVisitor<RelOptUtil.Logic,
RelOptUtil.Logic> - Overrides:
visitSubQuery
in classRexUnaryBiVisitor<@Nullable RelOptUtil.Logic>
-