public class FilterExtractor
extends java.lang.Object
PColFilterExtractor
We traverse the expression plan bottom up and separate it into two plans
- pushdownExprPlan, plan that can be pushed down to the loader and
- filterExprPlan, remaining plan that needs to be evaluated by pigModifier and Type | Field and Description |
---|---|
protected LogicalExpressionPlan |
filteredPlan
Plan that is created after all pushable filters are removed
|
protected LogicalExpressionPlan |
originalPlan
We visit this plan to create the filteredPlan
|
protected LogicalExpressionPlan |
pushdownExprPlan
Plan that can be pushed down
|
Constructor and Description |
---|
FilterExtractor(LogicalExpressionPlan plan,
java.util.List<java.lang.String> partitionCols) |
Modifier and Type | Method and Description |
---|---|
boolean |
canPushDown() |
static Expression |
getExpression(LogicalExpression op) |
LogicalExpressionPlan |
getFilteredPlan() |
Expression |
getPColCondition() |
boolean |
isFilterRemovable() |
void |
visit() |
protected LogicalExpressionPlan originalPlan
protected LogicalExpressionPlan filteredPlan
protected LogicalExpressionPlan pushdownExprPlan
public FilterExtractor(LogicalExpressionPlan plan, java.util.List<java.lang.String> partitionCols)
plan
- logical plan corresponding the filter's comparison conditionpartitionCols
- list of partition columns of the table which is
being loaded in the LOAD statement which is input to the filterpublic void visit() throws FrontendException
FrontendException
public LogicalExpressionPlan getFilteredPlan()
public boolean canPushDown()
public boolean isFilterRemovable()
public Expression getPColCondition()
public static Expression getExpression(LogicalExpression op) throws FrontendException
FrontendException
Copyright © 2007-2012 The Apache Software Foundation