org.apache.pig.newplan.logical.relational
Class LOJoin

java.lang.Object
  extended by org.apache.pig.newplan.Operator
      extended by org.apache.pig.newplan.logical.relational.LogicalRelationalOperator
          extended by org.apache.pig.newplan.logical.relational.LOJoin

public class LOJoin
extends LogicalRelationalOperator


Nested Class Summary
static class LOJoin.JOINTYPE
          Enum for the type of join
 
Field Summary
static Integer OPTION_JOIN
          static constant to refer to the option of selecting a join type
 
Fields inherited from class org.apache.pig.newplan.logical.relational.LogicalRelationalOperator
alias, lineNum, mCustomPartitioner, mPinnedOptions, requestedParallelism, schema
 
Fields inherited from class org.apache.pig.newplan.Operator
annotations, hashPrime, location, name, plan
 
Constructor Summary
LOJoin(LogicalPlan plan)
           
LOJoin(LogicalPlan plan, MultiMap<Integer,LogicalExpressionPlan> joinPlans, LOJoin.JOINTYPE jt, boolean[] isInner)
           
 
Method Summary
 void accept(PlanVisitor v)
          Accept a visitor at this node in the graph.
 MultiMap<Integer,LogicalExpressionPlan> getExpressionPlans()
          Get all of the expressions plans that are in this join.
 Collection<LogicalExpressionPlan> getExpressionPlanValues()
           
 boolean[] getInnerFlags()
           
 List<Operator> getInputs(LogicalPlan plan)
           
 Collection<LogicalExpressionPlan> getJoinPlan(int inputIndex)
           
 LOJoin.JOINTYPE getJoinType()
           
 String getName()
           
 LogicalSchema getSchema()
          Get the schema for the output of this relational operator.
 boolean isEqual(Operator other)
          This is like a shallow equals comparison.
 boolean isInner(int inputIndex)
           
 void resetJoinType()
           
 void setInnerFlags(boolean[] isInner)
           
 void setJoinPlans(MultiMap<Integer,LogicalExpressionPlan> joinPlans)
           
 void setJoinType(LOJoin.JOINTYPE jt)
           
 
Methods inherited from class org.apache.pig.newplan.logical.relational.LogicalRelationalOperator
checkEquality, fixDuplicateUids, getAlias, getCustomPartitioner, getLineNumber, getRequestedParallelism, isPinnedOption, neverUseForRealSetSchema, pinOption, resetSchema, resetUid, setAlias, setCustomPartitioner, setRequestedParallelism, setSchema, toString
 
Methods inherited from class org.apache.pig.newplan.Operator
annotate, getAnnotation, getLocation, getPlan, removeAnnotation, setLocation, setPlan
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

OPTION_JOIN

public static final Integer OPTION_JOIN
static constant to refer to the option of selecting a join type

Constructor Detail

LOJoin

public LOJoin(LogicalPlan plan)

LOJoin

public LOJoin(LogicalPlan plan,
              MultiMap<Integer,LogicalExpressionPlan> joinPlans,
              LOJoin.JOINTYPE jt,
              boolean[] isInner)
Method Detail

setJoinPlans

public void setJoinPlans(MultiMap<Integer,LogicalExpressionPlan> joinPlans)

setInnerFlags

public void setInnerFlags(boolean[] isInner)

setJoinType

public void setJoinType(LOJoin.JOINTYPE jt)

isInner

public boolean isInner(int inputIndex)

getInnerFlags

public boolean[] getInnerFlags()

getJoinType

public LOJoin.JOINTYPE getJoinType()

resetJoinType

public void resetJoinType()

getJoinPlan

public Collection<LogicalExpressionPlan> getJoinPlan(int inputIndex)

getExpressionPlans

public MultiMap<Integer,LogicalExpressionPlan> getExpressionPlans()
Get all of the expressions plans that are in this join.

Returns:
collection of all expression plans.

getExpressionPlanValues

public Collection<LogicalExpressionPlan> getExpressionPlanValues()

getSchema

public LogicalSchema getSchema()
                        throws FrontendException
Description copied from class: LogicalRelationalOperator
Get the schema for the output of this relational operator. This does not merely return the schema variable. If schema is not yet set, this will attempt to construct it. Therefore it is abstract since each operator will need to construct its schema differently.

Specified by:
getSchema in class LogicalRelationalOperator
Returns:
the schema
Throws:
FrontendException

accept

public void accept(PlanVisitor v)
            throws FrontendException
Description copied from class: Operator
Accept a visitor at this node in the graph.

Specified by:
accept in class Operator
Parameters:
v - Visitor to accept.
Throws:
FrontendException

isEqual

public boolean isEqual(Operator other)
                throws FrontendException
Description copied from class: Operator
This is like a shallow equals comparison. It returns true if two operators have equivalent properties even if they are different objects. Here properties mean equivalent plan and equivalent name.

Specified by:
isEqual in class Operator
Returns:
true if two object have equivalent properties, else false
Throws:
FrontendException

getName

public String getName()
Overrides:
getName in class Operator

getInputs

public List<Operator> getInputs(LogicalPlan plan)


Copyright © 2007-2012 The Apache Software Foundation