|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.pig.impl.plan.Operator<LOVisitor>
org.apache.pig.impl.logicalLayer.LogicalOperator
org.apache.pig.impl.logicalLayer.RelationalOperator
org.apache.pig.impl.logicalLayer.LOJoin
public class LOJoin
Nested Class Summary | |
---|---|
static class |
LOJoin.JOINTYPE
Enum for the type of join |
Field Summary |
---|
Fields inherited from class org.apache.pig.impl.logicalLayer.LogicalOperator |
---|
mAlias, mIsProjectionMapComputed, mIsSchemaComputed, mPlan, mProjectionMap, mRequestedParallelism, mSchema, mType |
Fields inherited from class org.apache.pig.impl.plan.Operator |
---|
mKey |
Constructor Summary | |
---|---|
LOJoin(LogicalPlan plan,
OperatorKey k,
MultiMap<LogicalOperator,LogicalPlan> joinPlans,
LOJoin.JOINTYPE jt,
boolean[] isInner)
|
Method Summary | |
---|---|
protected Object |
clone()
|
byte |
getAtomicJoinColType()
This can be used to get the merged type of output join col only when the join col is of atomic type |
boolean[] |
getInnerFlags()
|
List<LogicalOperator> |
getInputs()
|
MultiMap<LogicalOperator,LogicalPlan> |
getJoinPlans()
|
LOJoin.JOINTYPE |
getJoinType()
Returns the type of join. |
ProjectionMap |
getProjectionMap()
Produce a map describing how this operator modifies its projection. |
List<RequiredFields> |
getRelevantInputs(int output,
int column)
Get relevant input columns of a particular output column. |
List<RequiredFields> |
getRequiredFields()
Get a list of fields that this operator requires. |
Schema |
getSchema()
Get a copy of the schema for the output of this operator. |
Schema |
getTupleJoinSchema()
|
boolean |
isTupleJoinCol()
|
String |
name()
|
boolean |
pruneColumns(List<Pair<Integer,Integer>> columns)
|
void |
rewire(Operator oldPred,
int oldPredIndex,
Operator newPred,
boolean useOldPred)
Make any necessary changes to a node based on a change of position in the plan. |
void |
setJoinPlans(MultiMap<LogicalOperator,LogicalPlan> joinPlans)
|
boolean |
supportsMultipleInputs()
Indicates whether this operator supports multiple inputs. |
void |
switchJoinColPlanOp(LogicalOperator oldOp,
LogicalOperator newOp)
This does switch the mapping oldOp -> List of inner plans to newOp -> List of inner plans which is useful when there is a structural change in LogicalPlan |
void |
unsetSchema()
Unset the schema as if it had not been calculated. |
void |
visit(LOVisitor v)
Visit this node with the provided visitor. |
Methods inherited from class org.apache.pig.impl.logicalLayer.RelationalOperator |
---|
pruneColumnInPlan, regenerateProjectionMap, unsetProjectionMap |
Methods inherited from class org.apache.pig.impl.logicalLayer.LogicalOperator |
---|
forceSchema, getAlias, getOperatorKey, getPlan, getRequestedParallelism, getType, reconcileSchema, regenerateSchema, setAlias, setCanonicalNames, setPlan, setRequestedParallelism, setSchema, setSchemaComputed, setType, supportsMultipleOutputs, toString |
Methods inherited from class org.apache.pig.impl.plan.Operator |
---|
compareTo, equals, hashCode |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public LOJoin(LogicalPlan plan, OperatorKey k, MultiMap<LogicalOperator,LogicalPlan> joinPlans, LOJoin.JOINTYPE jt, boolean[] isInner)
plan
- LogicalPlan this operator is a part of.k
- OperatorKey for this operatorjoinPlans
- the join columnsjt
- indicates the type of join - regular, skewed fragment replicated or merge joinMethod Detail |
---|
public List<LogicalOperator> getInputs()
public MultiMap<LogicalOperator,LogicalPlan> getJoinPlans()
public void setJoinPlans(MultiMap<LogicalOperator,LogicalPlan> joinPlans)
public LOJoin.JOINTYPE getJoinType()
public String name()
name
in class Operator<LOVisitor>
public boolean supportsMultipleInputs()
Operator
supportsMultipleInputs
in class Operator<LOVisitor>
public Schema getSchema() throws FrontendException
LogicalOperator
getSchema
in class LogicalOperator
FrontendException
public boolean isTupleJoinCol()
public void visit(LOVisitor v) throws VisitorException
LogicalOperator
visit
in class LogicalOperator
v
- Visitor to visit with.
VisitorException
- if the visitor has a problem.public void switchJoinColPlanOp(LogicalOperator oldOp, LogicalOperator newOp)
oldOp
- the old operatornewOp
- the new operatorpublic void unsetSchema() throws VisitorException
LogicalOperator
unsetSchema
in class LogicalOperator
VisitorException
public byte getAtomicJoinColType() throws FrontendException
FrontendException
public Schema getTupleJoinSchema() throws FrontendException
FrontendException
protected Object clone() throws CloneNotSupportedException
clone
in class LogicalOperator
CloneNotSupportedException
Do not use the clone method directly. Operators are cloned when logical plans
are cloned using {@link LogicalPlanCloner}
public ProjectionMap getProjectionMap()
RelationalOperator
getProjectionMap
in class RelationalOperator
public List<RequiredFields> getRequiredFields()
RelationalOperator
getRequiredFields
in class RelationalOperator
public void rewire(Operator oldPred, int oldPredIndex, Operator newPred, boolean useOldPred) throws PlanException
Operator
rewire
in class Operator<LOVisitor>
oldPred
- Operator that was previously the predecessor.oldPredIndex
- position of the old predecessor in the list of predecessorsnewPred
- Operator that will now be the predecessor.useOldPred
- If true use oldPred's projection map for the rewire; otherwise
use newPred's projection map
PlanException
public List<RequiredFields> getRelevantInputs(int output, int column) throws FrontendException
RelationalOperator
getRelevantInputs
in class RelationalOperator
output
- output index. Only LOSplit have output other than 0 currentlycolumn
- output column
FrontendException
public boolean[] getInnerFlags()
public boolean pruneColumns(List<Pair<Integer,Integer>> columns) throws FrontendException
pruneColumns
in class RelationalOperator
FrontendException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |