public class ExprWalkerInfo extends Object implements NodeProcessorCtx
Modifier and Type | Field and Description |
---|---|
protected static org.apache.commons.logging.Log |
LOG |
Constructor and Description |
---|
ExprWalkerInfo() |
ExprWalkerInfo(Operator<? extends OperatorDesc> op) |
Modifier and Type | Method and Description |
---|---|
void |
addAlias(ExprNodeDesc expr,
String alias)
Adds the specified alias to the specified expr.
|
void |
addConvertedNode(ExprNodeDesc oldNode,
ExprNodeDesc newNode)
adds a replacement node for this expression.
|
void |
addFinalCandidate(ExprNodeDesc expr)
Adds the specified expr as the top-most pushdown expr (ie all its children
can be pushed).
|
void |
addFinalCandidate(String alias,
ExprNodeDesc expr) |
void |
addNonFinalCandidate(ExprNodeDesc expr)
Adds the specified expr as a non-final candidate
|
void |
addPushDowns(String alias,
List<ExprNodeDesc> pushDowns)
Adds the passed list of pushDowns for the alias.
|
String |
getAlias(ExprNodeDesc expr)
Returns the alias of the specified expr.
|
ExprNodeDesc |
getConvertedNode(ExprNodeDesc nd) |
Map<String,List<ExprNodeDesc>> |
getFinalCandidates()
Returns the list of pushdown expressions for each alias that appear in the
current operator's RowResolver.
|
Map<ExprNodeDesc,ExprNodeDesc> |
getNewToOldExprMap() |
Map<String,List<ExprNodeDesc>> |
getNonFinalCandidates()
Returns list of non-final candidate predicate for each map.
|
Operator<? extends OperatorDesc> |
getOp() |
Map<String,List<ExprNodeDesc>> |
getResidualPredicates(boolean clear) |
boolean |
hasAnyCandidates() |
boolean |
isCandidate(ExprNodeDesc expr)
Returns true if the specified expression is pushdown candidate else false.
|
boolean |
isDeterministic() |
void |
merge(ExprWalkerInfo ewi)
Merges the specified pushdown predicates with the current class.
|
void |
setDeterministic(boolean b)
sets the deterministic flag for this expression.
|
void |
setIsCandidate(ExprNodeDesc expr,
boolean b)
Marks the specified expr to the specified value.
|
public ExprWalkerInfo()
public ExprWalkerInfo(Operator<? extends OperatorDesc> op)
public Operator<? extends OperatorDesc> getOp()
public Map<ExprNodeDesc,ExprNodeDesc> getNewToOldExprMap()
public ExprNodeDesc getConvertedNode(ExprNodeDesc nd)
public void addConvertedNode(ExprNodeDesc oldNode, ExprNodeDesc newNode)
oldNode
- original nodenewNode
- new nodepublic boolean isCandidate(ExprNodeDesc expr)
expr
- public void setIsCandidate(ExprNodeDesc expr, boolean b)
expr
- b
- canpublic String getAlias(ExprNodeDesc expr)
expr
- public void addAlias(ExprNodeDesc expr, String alias)
expr
- alias
- public void addFinalCandidate(ExprNodeDesc expr)
expr
- public void addFinalCandidate(String alias, ExprNodeDesc expr)
public void addPushDowns(String alias, List<ExprNodeDesc> pushDowns)
alias
- pushDowns
- public Map<String,List<ExprNodeDesc>> getFinalCandidates()
public boolean hasAnyCandidates()
public void addNonFinalCandidate(ExprNodeDesc expr)
expr
- public Map<String,List<ExprNodeDesc>> getNonFinalCandidates()
public Map<String,List<ExprNodeDesc>> getResidualPredicates(boolean clear)
public void merge(ExprWalkerInfo ewi)
ewi
- ExpressionWalkerInfopublic void setDeterministic(boolean b)
b
- deterministic or notpublic boolean isDeterministic()
Copyright © 2017 The Apache Software Foundation. All rights reserved.