org.apache.pig.backend.hadoop.executionengine.physicalLayer.plans
Class DotPOPrinter

java.lang.Object
  extended by org.apache.pig.impl.plan.PlanDumper<E,P,S>
      extended by org.apache.pig.impl.plan.DotPlanDumper<PhysicalOperator,PhysicalPlan,PhysicalOperator,PhysicalPlan>
          extended by org.apache.pig.backend.hadoop.executionengine.physicalLayer.plans.DotPOPrinter

public class DotPOPrinter
extends DotPlanDumper<PhysicalOperator,PhysicalPlan,PhysicalOperator,PhysicalPlan>

This class can print a physical plan in the DOT format. It uses clusters to illustrate nesting. If "verbose" is off, it will skip any nesting.


Field Summary
 
Fields inherited from class org.apache.pig.impl.plan.DotPlanDumper
mMultiInputSubgraphs, mMultiOutputSubgraphs, mSubgraphs
 
Fields inherited from class org.apache.pig.impl.plan.PlanDumper
isVerbose, plan, ps
 
Constructor Summary
DotPOPrinter(PhysicalPlan plan, PrintStream ps)
           
DotPOPrinter(PhysicalPlan plan, PrintStream ps, boolean isSubGraph, Set<Operator> subgraphs, Set<Operator> multiInputSubgraphs, Set<Operator> multiOutputSubgraphs)
           
 
Method Summary
protected  String[] getAttributes(PhysicalOperator op)
          Used to generate the the attributes of a node
protected  Collection<PhysicalPlan> getMultiOutputNestedPlans(PhysicalOperator op)
          Used to determine if an operator has nested output plans
protected  String getName(PhysicalOperator op)
          Used to generate the label for an operator.
protected  Collection<PhysicalPlan> getNestedPlans(PhysicalOperator op)
          Used to determine if an operator has nested plans (without connections to in- or output operators.
protected  DotPlanDumper makeDumper(PhysicalPlan plan, PrintStream ps)
          makeDumper is a factory method.
 
Methods inherited from class org.apache.pig.impl.plan.DotPlanDumper
dump, dumpEdge, dumpInvisibleOperators, dumpMultiInputNestedOperator, dumpMultiOutputNestedOperator, dumpNestedOperator, dumpOperator
 
Methods inherited from class org.apache.pig.impl.plan.PlanDumper
getMultiInputNestedPlans, isVerbose, join, setVerbose
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DotPOPrinter

public DotPOPrinter(PhysicalPlan plan,
                    PrintStream ps)

DotPOPrinter

public DotPOPrinter(PhysicalPlan plan,
                    PrintStream ps,
                    boolean isSubGraph,
                    Set<Operator> subgraphs,
                    Set<Operator> multiInputSubgraphs,
                    Set<Operator> multiOutputSubgraphs)
Method Detail

makeDumper

protected DotPlanDumper makeDumper(PhysicalPlan plan,
                                   PrintStream ps)
Description copied from class: PlanDumper
makeDumper is a factory method. Used by subclasses to specify what dumper should handle the nested plan.

Overrides:
makeDumper in class DotPlanDumper<PhysicalOperator,PhysicalPlan,PhysicalOperator,PhysicalPlan>
Parameters:
plan - Plan that the new dumper should handle
Returns:
the dumper for plan

getName

protected String getName(PhysicalOperator op)
Description copied from class: DotPlanDumper
Used to generate the label for an operator.

Overrides:
getName in class DotPlanDumper<PhysicalOperator,PhysicalPlan,PhysicalOperator,PhysicalPlan>
Parameters:
op - operator to dump

getAttributes

protected String[] getAttributes(PhysicalOperator op)
Description copied from class: DotPlanDumper
Used to generate the the attributes of a node

Overrides:
getAttributes in class DotPlanDumper<PhysicalOperator,PhysicalPlan,PhysicalOperator,PhysicalPlan>
Parameters:
op - operator

getMultiOutputNestedPlans

protected Collection<PhysicalPlan> getMultiOutputNestedPlans(PhysicalOperator op)
Description copied from class: PlanDumper
Used to determine if an operator has nested output plans

Overrides:
getMultiOutputNestedPlans in class PlanDumper<PhysicalOperator,PhysicalPlan,PhysicalPlan>
Parameters:
op - operator
Returns:
Map describing the input to nested plan relationship.

getNestedPlans

protected Collection<PhysicalPlan> getNestedPlans(PhysicalOperator op)
Description copied from class: PlanDumper
Used to determine if an operator has nested plans (without connections to in- or output operators.

Overrides:
getNestedPlans in class PlanDumper<PhysicalOperator,PhysicalPlan,PhysicalPlan>
Parameters:
op - operator
Returns:
Collection of nested plans.


Copyright © ${year} The Apache Software Foundation