public abstract class PhysicalOperator extends Operator<PhyPlanVisitor> implements Illustrable, java.lang.Cloneable
Modifier and Type | Class and Description |
---|---|
static class |
PhysicalOperator.OriginalLocation |
Modifier and Type | Field and Description |
---|---|
protected java.lang.String |
alias |
protected Illustrator |
illustrator |
protected Tuple |
input |
protected boolean |
inputAttached |
protected java.util.List<PhysicalOperator> |
inputs |
protected LineageTracer |
lineageTracer |
protected java.util.List<PhysicalOperator> |
outputs |
protected PhysicalPlan |
parentPlan |
protected static PigLogger |
pigLogger |
protected static java.lang.ThreadLocal<PigProgressable> |
reporter |
protected int |
requestedParallelism |
protected Result |
res |
protected static Result |
RESULT_EMPTY |
protected static Result |
RESULT_EOP |
protected byte |
resultType |
protected static long |
serialVersionUID |
Constructor and Description |
---|
PhysicalOperator(OperatorKey k) |
PhysicalOperator(OperatorKey k,
int rp) |
PhysicalOperator(OperatorKey k,
int rp,
java.util.List<PhysicalOperator> inp) |
PhysicalOperator(OperatorKey k,
java.util.List<PhysicalOperator> inp) |
PhysicalOperator(PhysicalOperator copy) |
Modifier and Type | Method and Description |
---|---|
void |
addOriginalLocation(java.lang.String alias,
java.util.List<PhysicalOperator.OriginalLocation> originalLocations) |
void |
addOriginalLocation(java.lang.String alias,
SourceLocation sourceLocation) |
void |
attachInput(Tuple t)
Shorts the input path of this operator by providing the input tuple
directly
|
PhysicalOperator |
clone()
Make a deep copy of this operator.
|
protected void |
cloneHelper(PhysicalOperator op) |
void |
copyAliasFrom(PhysicalOperator op) |
void |
detachInput()
Detaches any tuples that are attached
|
java.lang.String |
getAlias() |
protected java.lang.String |
getAliasString() |
Illustrator |
getIllustrator() |
java.util.List<PhysicalOperator> |
getInputs() |
org.apache.commons.logging.Log |
getLogger() |
Result |
getNext(byte dataType)
Implementations that call into the different versions of getNext are often
identical, differing only in the signature of the getNext() call they make.
|
Result |
getNextBigDecimal() |
Result |
getNextBigInteger() |
Result |
getNextBoolean() |
Result |
getNextDataBag() |
Result |
getNextDataByteArray() |
Result |
getNextDateTime() |
Result |
getNextDouble() |
Result |
getNextFloat() |
Result |
getNextInteger() |
Result |
getNextLong() |
Result |
getNextMap() |
Result |
getNextString() |
Result |
getNextTuple() |
java.util.List<PhysicalOperator.OriginalLocation> |
getOriginalLocations() |
static PigLogger |
getPigLogger() |
static PigProgressable |
getReporter() |
int |
getRequestedParallelism() |
byte |
getResultType() |
boolean |
isAccumStarted() |
boolean |
isAccumulative() |
boolean |
isBlocking()
A blocking operator should override this to return true.
|
boolean |
isInputAttached() |
Result |
processInput()
A generic method for parsing input that either returns the attached input
if it exists or fetches it from its predecessor.
|
void |
reset()
Reset internal state in an operator.
|
void |
setAccumEnd() |
void |
setAccumStart() |
void |
setAccumulative() |
void |
setIllustrator(Illustrator illustrator) |
void |
setInputs(java.util.List<PhysicalOperator> inputs) |
void |
setParentPlan(PhysicalPlan physicalPlan) |
static void |
setPigLogger(PigLogger logger) |
static void |
setReporter(PigProgressable reporter) |
void |
setRequestedParallelism(int requestedParallelism) |
void |
setResultType(byte resultType) |
static void |
staticDataCleanup() |
abstract void |
visit(PhyPlanVisitor v)
Visit this node with the provided visitor.
|
compareTo, equals, getOperatorKey, getProjectionMap, hashCode, name, regenerateProjectionMap, rewire, supportsMultipleInputs, supportsMultipleOutputs, toString, unsetProjectionMap
finalize, getClass, notify, notifyAll, wait, wait, wait
illustratorMarkup
protected static final long serialVersionUID
protected static final Result RESULT_EMPTY
protected static final Result RESULT_EOP
protected int requestedParallelism
protected java.util.List<PhysicalOperator> inputs
protected java.util.List<PhysicalOperator> outputs
protected byte resultType
protected PhysicalPlan parentPlan
protected boolean inputAttached
protected Tuple input
protected Result res
protected java.lang.String alias
protected static java.lang.ThreadLocal<PigProgressable> reporter
protected static PigLogger pigLogger
protected LineageTracer lineageTracer
protected transient Illustrator illustrator
public PhysicalOperator(OperatorKey k)
public PhysicalOperator(OperatorKey k, int rp)
public PhysicalOperator(OperatorKey k, java.util.List<PhysicalOperator> inp)
public PhysicalOperator(OperatorKey k, int rp, java.util.List<PhysicalOperator> inp)
public PhysicalOperator(PhysicalOperator copy)
public void setIllustrator(Illustrator illustrator)
setIllustrator
in interface Illustrable
public Illustrator getIllustrator()
public int getRequestedParallelism()
public void setRequestedParallelism(int requestedParallelism)
public byte getResultType()
public java.lang.String getAlias()
protected java.lang.String getAliasString()
public void copyAliasFrom(PhysicalOperator op)
public void addOriginalLocation(java.lang.String alias, SourceLocation sourceLocation)
public void addOriginalLocation(java.lang.String alias, java.util.List<PhysicalOperator.OriginalLocation> originalLocations)
public java.util.List<PhysicalOperator.OriginalLocation> getOriginalLocations()
public void setAccumulative()
public boolean isAccumulative()
public void setAccumStart()
public boolean isAccumStarted()
public void setAccumEnd()
public void setResultType(byte resultType)
public java.util.List<PhysicalOperator> getInputs()
public void setInputs(java.util.List<PhysicalOperator> inputs)
public boolean isInputAttached()
public void attachInput(Tuple t)
t
- -
The tuple that should be used as inputpublic void detachInput()
public boolean isBlocking()
public Result processInput() throws ExecException
ExecException
public abstract void visit(PhyPlanVisitor v) throws VisitorException
Operator
visit
in class Operator<PhyPlanVisitor>
v
- Visitor to visit with.VisitorException
- if the visitor has a problem.public Result getNext(byte dataType) throws ExecException
dataType
- Describes the type of obj; a byte from DataType.ExecException
public Result getNextInteger() throws ExecException
ExecException
public Result getNextLong() throws ExecException
ExecException
public Result getNextDouble() throws ExecException
ExecException
public Result getNextFloat() throws ExecException
ExecException
public Result getNextDateTime() throws ExecException
ExecException
public Result getNextString() throws ExecException
ExecException
public Result getNextDataByteArray() throws ExecException
ExecException
public Result getNextMap() throws ExecException
ExecException
public Result getNextBoolean() throws ExecException
ExecException
public Result getNextTuple() throws ExecException
ExecException
public Result getNextDataBag() throws ExecException
ExecException
public Result getNextBigInteger() throws ExecException
ExecException
public Result getNextBigDecimal() throws ExecException
ExecException
public void reset()
public static PigProgressable getReporter()
public static void setReporter(PigProgressable reporter)
reporter
- PigProgressable to be stored in threadlocalpublic static void staticDataCleanup()
public PhysicalOperator clone() throws java.lang.CloneNotSupportedException
clone
in class Operator<PhyPlanVisitor>
java.lang.CloneNotSupportedException
Do not use the clone method directly. Operators are cloned when logical plans
are cloned using {@link LogicalPlanCloner}
protected void cloneHelper(PhysicalOperator op)
public void setParentPlan(PhysicalPlan physicalPlan)
physicalPlan
- public org.apache.commons.logging.Log getLogger()
public static void setPigLogger(PigLogger logger)
public static PigLogger getPigLogger()
Copyright © 2007-2012 The Apache Software Foundation