planetj.dataengine.autorun
Class AutoRunTask

java.lang.Object
  |
  +--java.util.TimerTask
        |
        +--planetj.util.CMTimerTask
              |
              +--planetj.dataengine.task.DataEngineTimerTask
                    |
                    +--planetj.dataengine.autorun.AutoRunTask
All Implemented Interfaces:
Runnable
Direct Known Subclasses:
BatchProcessTask, EmailTask

public abstract class AutoRunTask
extends DataEngineTimerTask

Describes how an Operation should be automatically run. All subclasses must provide a default constructor.


Method Summary
abstract  void autoRun()
          The action to be performed by this task.
 Object clone()
          Clones this task.
 AutoRunTask cloneTask()
          Clones this task.
 AutoRunOperation getAutoRunOperation()
          Gets this AutoRunTask's source operation (the operation which defines this task)
 int getAutoRunOperationId()
          Gets the ID of this AutoRunTask's source operation (the operation which defines this task)
abstract  long getFrequency()
          Gets the frequency (in seconds) at which the task should run
 String getMetadataAlias()
          Gets the metadata alias this AutoRunTask is using
abstract  Date getStartTime()
          Gets the exact day and time when this task should begin executing
 Operation getTargetOperation()
          Gets this AutoRunTask's target operation
 int getTargetOperationId()
          Gets the ID of this AutoRunTask's target operation (the operation which will be autorun)
 void performTask()
          The action to be performed by this task.
 void setAutoRunOperationId(int newAutoRunOperationId)
          Sets the ID of this AutoRunTask's source operation (the operation which defines this task)
 
Methods inherited from class planetj.dataengine.task.DataEngineTimerTask
postTask, preTask
 
Methods inherited from class planetj.util.CMTimerTask
addListener, getNewTaskEvent, getTaskEvent, removeListener, run
 
Methods inherited from class java.util.TimerTask
cancel, scheduledExecutionTime
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

autoRun

public abstract void autoRun()
                      throws CMException
The action to be performed by this task.

CMException

clone

public Object clone()
Clones this task. If this method is overriden, you should invoke it on the superclass first

Overrides:
clone in class Object

cloneTask

public AutoRunTask cloneTask()
Clones this task. If this method is overriden, you should invoke it on the superclass first


getAutoRunOperation

public AutoRunOperation getAutoRunOperation()
                                     throws CMException
Gets this AutoRunTask's source operation (the operation which defines this task)

CMException

getAutoRunOperationId

public int getAutoRunOperationId()
Gets the ID of this AutoRunTask's source operation (the operation which defines this task)


getFrequency

public abstract long getFrequency()
                           throws CMException
Gets the frequency (in seconds) at which the task should run

CMException

getMetadataAlias

public String getMetadataAlias()
Gets the metadata alias this AutoRunTask is using


getStartTime

public abstract Date getStartTime()
                           throws CMException
Gets the exact day and time when this task should begin executing

CMException

getTargetOperation

public Operation getTargetOperation()
                             throws CMException
Gets this AutoRunTask's target operation

CMException

getTargetOperationId

public int getTargetOperationId()
Gets the ID of this AutoRunTask's target operation (the operation which will be autorun)


performTask

public final void performTask()
The action to be performed by this task.

Specified by:
performTask in class CMTimerTask

setAutoRunOperationId

public void setAutoRunOperationId(int newAutoRunOperationId)
Sets the ID of this AutoRunTask's source operation (the operation which defines this task)