|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcascading.pipe.Pipe
public class Pipe
Class Pipe is used to name branches in pipe assemblies, and as a base class for core
processing model types, specifically Each, Every, GroupBy,
CoGroup, Merge, HashJoin, and SubAssembly.
CoGroup or HashJoin pipe.
A merge can be achieved by passing two or more Pipe instances to a GroupBy or Merge pipe.
Each,
Every,
GroupBy,
Merge,
CoGroup,
HashJoin,
SubAssembly,
Serialized Form| Field Summary | |
|---|---|
protected ConfigDef |
configDef
|
protected Pipe |
previous
Field previous |
protected ConfigDef |
stepConfigDef
|
| Constructor Summary | |
|---|---|
protected |
Pipe()
|
protected |
Pipe(Pipe previous)
|
|
Pipe(String name)
Constructor Pipe creates a new Pipe instance with the given name. |
|
Pipe(String name,
Pipe previous)
Constructor Pipe creates a new Pipe instance with the given name and previous Pipe instance. |
| Method Summary | |
|---|---|
boolean |
equals(Object object)
|
ConfigDef |
getConfigDef()
Returns a ConfigDef instance that allows for local properties to be set and made available via
a resulting FlowProcess instance when the pipe is invoked. |
Pipe[] |
getHeads()
Method getHeads returns the first Pipe instances in this pipe assembly. |
String |
getName()
Get the name of this pipe. |
Pipe[] |
getPrevious()
Get all the upstream pipes this pipe is connected to. |
ConfigDef |
getStepConfigDef()
Returns a ConfigDef instance that allows for process level properties to be set and made available via
a resulting FlowProcess instance when the pipe is invoked. |
String |
getTrace()
Method getTrace returns a String that pinpoint where this instance was created for debugging. |
boolean |
hasConfigDef()
Returns true if there are properties in the configDef instance. |
int |
hashCode()
|
boolean |
hasStepConfigDef()
Returns true if there are properties in the processConfigDef instance. |
boolean |
isEquivalentTo(FlowElement element)
|
static Pipe[] |
named(String name,
Pipe... tails)
|
static String[] |
names(Pipe... tails)
Convenience method for finding all Pipe names in an assembly. |
cascading.flow.planner.Scope |
outgoingScopeFor(Set<cascading.flow.planner.Scope> incomingScopes)
Method outgoingScopeFor returns the Scope this FlowElement hands off to the next FlowElement. |
static Pipe[] |
pipes(Pipe... pipes)
Convenience method to create an array of Pipe instances. |
String |
print(cascading.flow.planner.Scope scope)
Method print is used internally. |
protected void |
printInternal(StringBuffer buffer,
cascading.flow.planner.Scope scope)
|
Fields |
resolveIncomingOperationArgumentFields(cascading.flow.planner.Scope incomingScope)
Method resolveIncomingOperationArgumentFields returns the Fields outgoing from the previous FlowElement that are consumable by this FlowElement when preparing Operation arguments. |
Fields |
resolveIncomingOperationPassThroughFields(cascading.flow.planner.Scope incomingScope)
Method resolveIncomingOperationPassThroughFields returns the Fields outgoing from the previous FlowElement that are consumable by this FlowElement when preparing the Pipe outgoing tuple. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected Pipe previous
protected ConfigDef configDef
protected ConfigDef stepConfigDef
| Constructor Detail |
|---|
protected Pipe()
@ConstructorProperties(value="previous") protected Pipe(Pipe previous)
@ConstructorProperties(value="name") public Pipe(String name)
name - name for this branch of Pipes
@ConstructorProperties(value={"name","previous"})
public Pipe(String name,
Pipe previous)
name - name for this branch of Pipesprevious - previous Pipe to receive input Tuples from| Method Detail |
|---|
public static Pipe[] pipes(Pipe... pipes)
pipes - vararg list of pipes
public static String[] names(Pipe... tails)
tails - vararg list of all tails in given assembly
public static Pipe[] named(String name,
Pipe... tails)
public String getName()
public Pipe[] getPrevious()
public ConfigDef getConfigDef()
ConfigDef instance that allows for local properties to be set and made available via
a resulting FlowProcess instance when the pipe is invoked.
Any properties set on the configDef will not show up in any Flow or
FlowStep process level configuration, but will override any of those values as seen by the
current Pipe instance.
getConfigDef in interface FlowElementpublic boolean hasConfigDef()
true if there are properties in the configDef instance.
hasConfigDef in interface FlowElementpublic ConfigDef getStepConfigDef()
ConfigDef instance that allows for process level properties to be set and made available via
a resulting FlowProcess instance when the pipe is invoked.
Any properties set on the stepConfigDef will not show up in any Flow configuration, but will show up in
the current process FlowStep (in Hadoop the MapReduce jobconf). Any value set in the
stepConfigDef will be overridden by the pipe local #getConfigDef instance.
Use this method to tweak properties in the process step this pipe instance is planned into. In the case of the
Hadoop platform, when set on a GroupBy instance, the number of reducers can be modified.
getStepConfigDef in interface FlowElementpublic boolean hasStepConfigDef()
true if there are properties in the processConfigDef instance.
hasStepConfigDef in interface FlowElementpublic Pipe[] getHeads()
public cascading.flow.planner.Scope outgoingScopeFor(Set<cascading.flow.planner.Scope> incomingScopes)
FlowElement
outgoingScopeFor in interface FlowElementincomingScopes - of type Setpublic Fields resolveIncomingOperationArgumentFields(cascading.flow.planner.Scope incomingScope)
FlowElement
resolveIncomingOperationArgumentFields in interface FlowElementincomingScope - of type Scope
public Fields resolveIncomingOperationPassThroughFields(cascading.flow.planner.Scope incomingScope)
FlowElement
resolveIncomingOperationPassThroughFields in interface FlowElementincomingScope - of type Scope
public String getTrace()
public String toString()
toString in class Objectpublic boolean isEquivalentTo(FlowElement element)
isEquivalentTo in interface FlowElementpublic boolean equals(Object object)
equals in class Objectpublic int hashCode()
hashCode in class Objectpublic String print(cascading.flow.planner.Scope scope)
scope - of type Scope
protected void printInternal(StringBuffer buffer,
cascading.flow.planner.Scope scope)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||