org.oddjob.jobs.job
Class DependsJob

java.lang.Object
  extended by org.oddjob.framework.BaseComponent
      extended by org.oddjob.framework.BasePrimary
          extended by org.oddjob.framework.SimpleJob
              extended by org.oddjob.jobs.job.DependsJob
All Implemented Interfaces:
Runnable, ArooaContextAware, ArooaSessionAware, Forceable, PropertyChangeNotifier, Iconic, LogEnabled, Resetable, StateListener, Stateful, Stoppable

Deprecated. Use RunJob instead.

public class DependsJob
extends SimpleJob
implements Stoppable, StateListener

Description

This job is deprecated, use RunJob instead.

A job which depends on another job.

This job was intended to simulate Ant's dependency like functionality but the run job is better.
Author:
Rob Gordon

Field Summary
 
Fields inherited from class org.oddjob.framework.SimpleJob
stateHandler, stop
 
Fields inherited from class org.oddjob.framework.BaseComponent
iconHelper
 
Constructor Summary
DependsJob()
          Deprecated.  
 
Method Summary
protected  int execute()
          Deprecated. Execute this job.
 Stateful getJob()
          Deprecated. Get the node to stop.
 void jobStateChange(StateEvent event)
          Deprecated. Triggered when the job state changes.
 void setJob(Stateful node)
          Deprecated. Set the stop node directly.
 
Methods inherited from class org.oddjob.framework.SimpleJob
fireDestroyedState, force, getStateChanger, hardReset, onDestroy, onReset, onStop, run, sleep, softReset, stateHandler, stop
 
Methods inherited from class org.oddjob.framework.BasePrimary
configure, getName, logger, logger, loggerName, save, setName, toString
 
Methods inherited from class org.oddjob.framework.BaseComponent
addIconListener, addPropertyChangeListener, addStateListener, configure, destroy, firePropertyChange, getArooaSession, iconForId, initialise, lastStateEvent, onConfigured, onInitialised, removeIconListener, removePropertyChangeListener, removeStateListener, save, setArooaContext, setArooaSession
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.oddjob.Stoppable
stop
 
Methods inherited from interface org.oddjob.Stateful
addStateListener, lastStateEvent, removeStateListener
 

Constructor Detail

DependsJob

public DependsJob()
Deprecated. 
Method Detail

setJob

public void setJob(Stateful node)
Deprecated. 
Set the stop node directly.

Parameters:
node - The node to stop.

getJob

public Stateful getJob()
Deprecated. 
Get the node to stop.

Returns:
The node.

execute

protected int execute()
               throws Throwable
Deprecated. 
Description copied from class: SimpleJob
Execute this job.

Specified by:
execute in class SimpleJob
Returns:
0 if the job is complete, anything else otherwise.
Throws:
Exception - If the unexpected occurs.
Throwable

jobStateChange

public void jobStateChange(StateEvent event)
Deprecated. 
Description copied from interface: StateListener
Triggered when the job state changes.

Specified by:
jobStateChange in interface StateListener
Parameters:
event - The job state event.