## cascading.flow
Class ProcessFlow<P>

    java.lang.Object
      cascading.flow.Flow
          cascading.flow.ProcessFlow<P>

All Implemented Interfaces:
  Runnable

    public class ProcessFlow<P>

extends Flow

Class ProcessFlow is a `Flow` subclass that supports custom Riffle jobs.

Use this class to allow custom Riffle jobs to participate in the `Cascade` scheduler. If other Flow instances in the Cascade share resources with this Flow instance, all participants will be scheduled according to their dependencies (topologically).

Nested Class Summary

Nested classes/interfaces inherited from class cascading.flow.Flow
`Flow.FlowHolder`

Field Summary

Fields inherited from class cascading.flow.Flow
`sources, stopJobsOnExit`

Constructor Summary
`ProcessFlow(Map<Object,Object> properties, String name, P process)` Constructor ProcessFlow creates a new ProcessFlow instance.
`ProcessFlow(String name, P process)` Constructor ProcessFlow creates a new ProcessFlow instance.

Method Summary
`void` `cleanup()`
`void` `complete()` Method complete starts the current Flow instance if it has not be previously started, then block until completion.
`P` `getProcess()` Method getProcess returns the process of this ProcessFlow object.
`void` `prepare()` Method prepare is used by a `Cascade` to notify the given Flow it should initialize or clear any resources necessary for `Flow.start()` to be called successfully.
`void` `setTapFromProcess()` Method setTapFromProcess build `Tap` instance for the give process incoming and outgoing dependencies.
`void` `start()` Method start begins the execution of this Flow instance.
`void` `stop()` Method stop stops all running jobs, killing any currently executing.
`String` `toString()`

Methods inherited from class cascading.flow.Flow

`addListener, areSinksStale, areSourcesNewer, deleteSinks, deleteSinksIfNotAppend, deleteSinksIfNotUpdate, getFlowSkipStrategy, getFlowStats, getHolder, getID, getJobConf, getJobPollingInterval, getJobPollingInterval, getMaxConcurrentSteps, getName, getPreserveTemporaryFiles, getProperty, getSink, getSinkModified, getSinks, getSinksCollection, getSources, getSourcesCollection, getSteps, getStopJobsOnExit, getSubmitPriority, getTraps, getTrapsCollection, hasListeners, isPreserveTemporaryFiles, isSkipFlow, isStopJobsOnExit, jobsAreLocal, openSink, openSink, openSource, openSource, openTapForRead, openTapForWrite, openTrap, openTrap, removeListener, run, setFlowSkipStrategy, setJobPollingInterval, setMaxConcurrentSteps, setName, setPreserveTemporaryFiles, setProperty, setSinks, setSources, setStepGraph, setStopJobsOnExit, setSubmitPriority, setTraps, tapPathExists, writeDOT, writeStepsDOT`

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

Constructor Detail

### ProcessFlow

    @ConstructorProperties(value={"name","process"})
    public ProcessFlow(String name,
                                                  P process)

  Constructor ProcessFlow creates a new ProcessFlow instance.

  Parameters:
    `name` - of type String
    `process` - of type JobConf

### ProcessFlow

    @ConstructorProperties(value={"properties","name","process"})
    public ProcessFlow(Map<Object,Object> properties,
                                                  String name,
                                                  P process)

  Constructor ProcessFlow creates a new ProcessFlow instance.

  Parameters:
    `properties` - of type Map<Object, Object>
    `name` - of type String
    `process` - of type P

Method Detail

### setTapFromProcess

    public void setTapFromProcess()

  Method setTapFromProcess build `Tap` instance for the give process incoming and outgoing dependencies.

  This method may be called repeatedly to re-configure the source and sink taps.

### getProcess

    public P getProcess()

  Method getProcess returns the process of this ProcessFlow object.

  Returns:
    the process (type P) of this ProcessFlow object.

### prepare

    public void prepare()

  Description copied from class: `Flow`
  Method prepare is used by a `Cascade` to notify the given Flow it should initialize or clear any resources necessary for `Flow.start()` to be called successfully.

  Specifically, this implementation calls `Flow.deleteSinksIfNotUpdate()`.

  Overrides:
    `prepare` in class `Flow`

### start

    public void start()

  Description copied from class: `Flow`
  Method start begins the execution of this Flow instance. It will return immediately. Use the method `Flow.complete()` to block until this Flow completes.

  Overrides:
    `start` in class `Flow`

### stop

    public void stop()

  Description copied from class: `Flow`
  Method stop stops all running jobs, killing any currently executing.

  Overrides:
    `stop` in class `Flow`

### complete

    public void complete()

  Description copied from class: `Flow`
  Method complete starts the current Flow instance if it has not be previously started, then block until completion.

  Overrides:
    `complete` in class `Flow`

### cleanup

    public void cleanup()

  Overrides:
    `cleanup` in class `Flow`

### toString

    public String toString()

  Overrides:
    `toString` in class `Flow`

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