## cascading.flow.stream
Class StreamGraph

    java.lang.Object
      cascading.flow.stream.StreamGraph

Direct Known Subclasses:
  StepStreamGraph

    public class StreamGraph

extends Object

Class StreamGraph is the operation pipeline used during processing. This an internal use only class.

Under some circumstances it may make sense to see the actual graph plan. To do so, enable one or both dot file properties, `ERROR_DOT_FILE_NAME` and `DOT_FILE_PATH`.

Field Summary
`static String` `DOT_FILE_PATH` Property denoting the path to write all stream graph dot files.
`static String` `ERROR_DOT_FILE_NAME` Property denoting the path and filename to write the failed stream graph dot file.

Constructor Summary
`StreamGraph()`

Method Summary
`void` `addHead(Duct head)`
`void` `addPath(Duct lhs, Duct rhs)`
`void` `addPath(Duct lhs, int ordinal, Duct rhs)`
`void` `addTail(Duct tail)`
`static LinkedList<List<Duct>>` `asPathList(List<org.jgrapht.GraphPath<Duct,DuctGraph.Ordinal>> paths)`
`void` `bind()`
`void` `cleanup()` Calls cleanup starting at the head and working forwards
`int` `countAllEventingPathsTo(Duct duct)` Returns all free paths to the current duct, usually a GroupGate.
`protected Duct` `createFork(Duct[] allNext)`
`Duct` `createNextFor(Duct current)`
`protected Duct` `createOpenReducingWindow(Duct next)`
`protected Duct` `createOpenWindow(Duct next)`
`Duct[]` `findAllNextFor(Duct current)`
`Duct[]` `findAllPreviousFor(Duct current)`
`Collection<Duct>` `getAllDucts()`
`Collection<Duct>` `getHeads()`
`protected Object` `getProperty(String name)`
`org.jgrapht.DirectedGraph` `getReversedGraph()`
`org.jgrapht.traverse.TopologicalOrderIterator<Duct,Integer>` `getReversedTopologicalOrderIterator()`
`Collection<Duct>` `getTails()`
`org.jgrapht.traverse.TopologicalOrderIterator<Duct,Integer>` `getTopologicalOrderIterator()`
`int` `ordinalBetween(Duct lhs, Duct rhs)`
`void` `prepare()` Calls prepare starting at the tail and working backwards
`void` `printGraph(String filename)`
`void` `printGraph(String id, String classifier, int discriminator)`
`void` `printGraphError()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### ERROR_DOT_FILE_NAME

    public static final String ERROR_DOT_FILE_NAME

  Property denoting the path and filename to write the failed stream graph dot file.

  See Also:
    Constant Field Values

### DOT_FILE_PATH

    public static final String DOT_FILE_PATH

  Property denoting the path to write all stream graph dot files. The filename will be generated based on platform properties.

  See Also:
    Constant Field Values

Constructor Detail

### StreamGraph

    public StreamGraph()

Method Detail

### getProperty

    protected Object getProperty(String name)

### addHead

    public void addHead(Duct head)

### addTail

    public void addTail(Duct tail)

### addPath

    public void addPath(Duct lhs,
                        Duct rhs)

### addPath

    public void addPath(Duct lhs,
                        int ordinal,
                        Duct rhs)

### bind

    public void bind()

### prepare

    public void prepare()

  Calls prepare starting at the tail and working backwards

### cleanup

    public void cleanup()

  Calls cleanup starting at the head and working forwards

### getHeads

    public Collection<Duct> getHeads()

### getTails

    public Collection<Duct> getTails()

### findAllNextFor

    public Duct[] findAllNextFor(Duct current)

### findAllPreviousFor

    public Duct[] findAllPreviousFor(Duct current)

### createNextFor

    public Duct createNextFor(Duct current)

### createOpenWindow

    protected Duct createOpenWindow(Duct next)

### createOpenReducingWindow

    protected Duct createOpenReducingWindow(Duct next)

### createFork

    protected Duct createFork(Duct[] allNext)

### countAllEventingPathsTo

    public int countAllEventingPathsTo(Duct duct)

  Returns all free paths to the current duct, usually a GroupGate.

  Paths all unique paths are counted, minus any immediate prior GroupGates as they block incoming paths into a single path

  Parameters:
    `duct` - of type Duct
  Returns:
    an int

### ordinalBetween

    public int ordinalBetween(Duct lhs,
                              Duct rhs)

### asPathList

    public static LinkedList<List<Duct>> asPathList(List<org.jgrapht.GraphPath<Duct,DuctGraph.Ordinal>> paths)

### getTopologicalOrderIterator

    public org.jgrapht.traverse.TopologicalOrderIterator<Duct,Integer> getTopologicalOrderIterator()

### getReversedTopologicalOrderIterator

    public org.jgrapht.traverse.TopologicalOrderIterator<Duct,Integer> getReversedTopologicalOrderIterator()

### getReversedGraph

    public org.jgrapht.DirectedGraph getReversedGraph()

### getAllDucts

    public Collection<Duct> getAllDucts()

### printGraphError

    public void printGraphError()

### printGraph

    public void printGraph(String id,
                           String classifier,
                           int discriminator)

### printGraph

    public void printGraph(String filename)

Copyright © 2007-2014 Concurrent, Inc. All Rights Reserved.