org.apache.pig.impl.logicalLayer
Class ProjectFixerUpper

java.lang.Object
  extended by org.apache.pig.impl.plan.PlanVisitor<LogicalOperator,LogicalPlan>
      extended by org.apache.pig.impl.logicalLayer.LOVisitor
          extended by org.apache.pig.impl.logicalLayer.ProjectFixerUpper

public class ProjectFixerUpper
extends LOVisitor

A class to visit all the projects and change them to attach to a new node. This class overrides all of the relational operators visit methods because it does not want to visit contained plans.


Field Summary
 
Fields inherited from class org.apache.pig.impl.plan.PlanVisitor
mCurrentWalker, mPlan
 
Constructor Summary
ProjectFixerUpper(LogicalPlan plan, LogicalOperator oldNode, int oldNodeIndex, LogicalOperator newNode, boolean useOldNode, LogicalOperator containingNode)
           
ProjectFixerUpper(LogicalPlan plan, LogicalOperator oldNode, LogicalOperator newNode, Map<Integer,Integer> projectionMapping)
           
 
Method Summary
 String toString()
           
protected  void visit(LOCogroup cg)
           
protected  void visit(LOFilter f)
           
protected  void visit(LOForEach f)
           
protected  void visit(LOProject p)
           
protected  void visit(LOSort s)
           
protected  void visit(LOSplit s)
           
protected  void visit(LOSplitOutput s)
           
 
Methods inherited from class org.apache.pig.impl.logicalLayer.LOVisitor
visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit
 
Methods inherited from class org.apache.pig.impl.plan.PlanVisitor
getPlan, popWalker, pushWalker, visit
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ProjectFixerUpper

public ProjectFixerUpper(LogicalPlan plan,
                         LogicalOperator oldNode,
                         int oldNodeIndex,
                         LogicalOperator newNode,
                         boolean useOldNode,
                         LogicalOperator containingNode)
                  throws VisitorException
Throws:
VisitorException

ProjectFixerUpper

public ProjectFixerUpper(LogicalPlan plan,
                         LogicalOperator oldNode,
                         LogicalOperator newNode,
                         Map<Integer,Integer> projectionMapping)
                  throws VisitorException
Throws:
VisitorException
Method Detail

visit

protected void visit(LOCogroup cg)
              throws VisitorException
Overrides:
visit in class LOVisitor
Parameters:
cg - the logical cogroup operator that has to be visited
Throws:
VisitorException

visit

protected void visit(LOSort s)
              throws VisitorException
Overrides:
visit in class LOVisitor
Parameters:
s - the logical sort operator that has to be visited
Throws:
VisitorException

visit

protected void visit(LOFilter f)
              throws VisitorException
Overrides:
visit in class LOVisitor
Parameters:
f - the logical filter operator that has to be visited
Throws:
VisitorException

visit

protected void visit(LOSplit s)
              throws VisitorException
Overrides:
visit in class LOVisitor
Parameters:
s - the logical split operator that has to be visited
Throws:
VisitorException

visit

protected void visit(LOSplitOutput s)
              throws VisitorException
Overrides:
visit in class LOVisitor
Throws:
VisitorException

visit

protected void visit(LOForEach f)
              throws VisitorException
Overrides:
visit in class LOVisitor
Parameters:
f - the logical foreach operator that has to be visited
Throws:
VisitorException

visit

protected void visit(LOProject p)
              throws VisitorException
Overrides:
visit in class LOVisitor
Throws:
VisitorException

toString

public String toString()
Overrides:
toString in class Object


Copyright © ${year} The Apache Software Foundation