org.eigenbase.rex
Class RexVisitorImpl<R>

java.lang.Object
  extended by org.eigenbase.rex.RexVisitorImpl<R>
All Implemented Interfaces:
RexVisitor<R>
Direct Known Subclasses:
CalcRelSplitter.HighestUsageFinder, CalcRelSplitter.ImplementTester, CalcRelSplitter.MaxInputFinder, ConvertMultiJoinRule.InputReferenceCounter, FarragoReduceExpressionsRule.ReducibleExprLocator, ProjectRelBase.Checker, PushProjector.InputSpecialOpFinder, RelMdUtil.CardOfProjExpr, RelOptUtil.InputFinder, RexChecker, RexMultisetUtil.RexCallMultisetOperatorCounter, RexOver.Finder, RexProgram.Marshaller, RexProgram.ReferenceCounter, RexProgramBuilder.UsageVisitor, RexToCalcTranslator.TranslationTester, RexUtil.ExpressionNormalizer, RexUtil.FieldAccessFinder, RexUtil.ForwardRefFinder, SargRexAnalyzer.NodeVisitor

public class RexVisitorImpl<R>
extends Object
implements RexVisitor<R>

Default implementation of RexVisitor, which visits each node but does nothing while it's there.


Field Summary
protected  boolean deep
           
 
Constructor Summary
protected RexVisitorImpl(boolean deep)
           
 
Method Summary
static boolean visitArrayAnd(RexVisitor<Boolean> visitor, RexNode[] exprs)
          Visits an array of expressions, returning the logical 'and' of their results.
static boolean visitArrayOr(RexVisitor<Boolean> visitor, RexNode[] exprs)
          Visits an array of expressions, returning the logical 'or' of their results.
 R visitCall(RexCall call)
           
 R visitCorrelVariable(RexCorrelVariable correlVariable)
           
 R visitDynamicParam(RexDynamicParam dynamicParam)
           
 R visitFieldAccess(RexFieldAccess fieldAccess)
           
 R visitInputRef(RexInputRef inputRef)
           
 R visitLiteral(RexLiteral literal)
           
 R visitLocalRef(RexLocalRef localRef)
           
 R visitOver(RexOver over)
           
 R visitRangeRef(RexRangeRef rangeRef)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

deep

protected final boolean deep
Constructor Detail

RexVisitorImpl

protected RexVisitorImpl(boolean deep)
Method Detail

visitInputRef

public R visitInputRef(RexInputRef inputRef)
Specified by:
visitInputRef in interface RexVisitor<R>

visitLocalRef

public R visitLocalRef(RexLocalRef localRef)
Specified by:
visitLocalRef in interface RexVisitor<R>

visitLiteral

public R visitLiteral(RexLiteral literal)
Specified by:
visitLiteral in interface RexVisitor<R>

visitOver

public R visitOver(RexOver over)
Specified by:
visitOver in interface RexVisitor<R>

visitCorrelVariable

public R visitCorrelVariable(RexCorrelVariable correlVariable)
Specified by:
visitCorrelVariable in interface RexVisitor<R>

visitCall

public R visitCall(RexCall call)
Specified by:
visitCall in interface RexVisitor<R>

visitDynamicParam

public R visitDynamicParam(RexDynamicParam dynamicParam)
Specified by:
visitDynamicParam in interface RexVisitor<R>

visitRangeRef

public R visitRangeRef(RexRangeRef rangeRef)
Specified by:
visitRangeRef in interface RexVisitor<R>

visitFieldAccess

public R visitFieldAccess(RexFieldAccess fieldAccess)
Specified by:
visitFieldAccess in interface RexVisitor<R>

visitArrayAnd

public static boolean visitArrayAnd(RexVisitor<Boolean> visitor,
                                    RexNode[] exprs)

Visits an array of expressions, returning the logical 'and' of their results.

If any of them returns false, returns false immediately; if they all return true, returns true.

See Also:
visitArrayOr(org.eigenbase.rex.RexVisitor, org.eigenbase.rex.RexNode[]), RexShuttle.visitArray(org.eigenbase.rex.RexNode[], boolean[])

visitArrayOr

public static boolean visitArrayOr(RexVisitor<Boolean> visitor,
                                   RexNode[] exprs)

Visits an array of expressions, returning the logical 'or' of their results.

If any of them returns true, returns true immediately; if they all return false, returns false.

See Also:
visitArrayAnd(org.eigenbase.rex.RexVisitor, org.eigenbase.rex.RexNode[]), RexShuttle.visitArray(org.eigenbase.rex.RexNode[], boolean[])