cascading.flow
Class FailingFlowListener

java.lang.Object
  extended by cascading.flow.LockingFlowListener
      extended by cascading.flow.FailingFlowListener
All Implemented Interfaces:
FlowListener

public class FailingFlowListener
extends LockingFlowListener


Nested Class Summary
static class FailingFlowListener.OnFail
           
 
Field Summary
 
Fields inherited from class cascading.flow.LockingFlowListener
completed, started, stopped, thrown
 
Constructor Summary
FailingFlowListener(FailingFlowListener.OnFail onFail)
           
 
Method Summary
 void onCompleted(Flow flow)
          The onCompleted event is fired when a Flow instance has completed all work whether if was success or failed.
 void onStarting(Flow flow)
          The onStarting event is fired when a Flow instance receives the start() message.
 void onStopping(Flow flow)
          The onStopping event is fired when a Flow instance receives the stop() message.
 boolean onThrowable(Flow flow, Throwable throwable)
          The onThrowable event is fired if any child FlowStep throws a Throwable type.
 
Methods inherited from class cascading.flow.LockingFlowListener
getJobsMap
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FailingFlowListener

public FailingFlowListener(FailingFlowListener.OnFail onFail)
Method Detail

onStarting

public void onStarting(Flow flow)
Description copied from interface: FlowListener
The onStarting event is fired when a Flow instance receives the start() message.

Specified by:
onStarting in interface FlowListener
Overrides:
onStarting in class LockingFlowListener

onStopping

public void onStopping(Flow flow)
Description copied from interface: FlowListener
The onStopping event is fired when a Flow instance receives the stop() message.

Specified by:
onStopping in interface FlowListener
Overrides:
onStopping in class LockingFlowListener

onCompleted

public void onCompleted(Flow flow)
Description copied from interface: FlowListener
The onCompleted event is fired when a Flow instance has completed all work whether if was success or failed. If there was a thrown exception, onThrowable will be fired before this event.

Specified by:
onCompleted in interface FlowListener
Overrides:
onCompleted in class LockingFlowListener

onThrowable

public boolean onThrowable(Flow flow,
                           Throwable throwable)
Description copied from interface: FlowListener
The onThrowable event is fired if any child FlowStep throws a Throwable type. This throwable is passed as an argument to the event. This event method should return true if the given throwable was handled and should not be rethrown from the Flow.complete() method.

Specified by:
onThrowable in interface FlowListener
Overrides:
onThrowable in class LockingFlowListener
Returns:
returns true if this listener has handled the given throwable


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