public class ExecutableTask extends java.lang.Object implements java.lang.Runnable, DatasetCollectionObserver
| Modifier and Type | Field and Description |
|---|---|
boolean |
executing |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object anObject) |
long |
getExecutionInterval()
For a task that needs to be executed periodically, this method is used to
retrieve the interval at which the task needs to be executed
periodically.
|
java.lang.String |
getIdentifier()
Retrieve the identifier for the executable task
|
long |
getInitialDelayForPeriodicTask()
This method returns the time at which the periodic task will execute for
the first time.
|
Operation |
getOperation()
Retrieve the operation that will be executed by this task
|
TaskLifecycleMetrics |
getTaskLifecycleMetrics()
Retrieve the TaskLifecyleMetrics associated with this task.
|
int |
hashCode() |
boolean |
isExecutePeriodically()
A check to see if the task in question needs to be executed periodically.
|
void |
onDataAvailability()
This method is invoked on the observers to reflect the availability of
new data in the dataset collection.
|
void |
onDatasetCollectionClosure()
This method is invoked on the observers to reflect the closure of the
dataset collection.
|
boolean |
passesReadinessCheck()
Checks to see if the task is ready for execution.
|
void |
run() |
void |
setExecutionStatus(int executionStatus)
Set the execution status for the lifecycle metrics.
|
void |
setTaskCompletionInfo(java.lang.String taskCompletionInfo)
Include some information about the completion of the task.
|
public java.lang.String getIdentifier()
public TaskLifecycleMetrics getTaskLifecycleMetrics()
public void setExecutionStatus(int executionStatus)
executionStatus - public void setTaskCompletionInfo(java.lang.String taskCompletionInfo)
taskCompletionInfo - public Operation getOperation()
public void run()
run in interface java.lang.Runnablepublic boolean passesReadinessCheck()
public void onDataAvailability()
DatasetCollectionObserveronDataAvailability in interface DatasetCollectionObserverpublic void onDatasetCollectionClosure()
DatasetCollectionObserveronDatasetCollectionClosure in interface DatasetCollectionObserverpublic boolean isExecutePeriodically()
true if the task needs to be executed periodically,
and false otherwise.public long getExecutionInterval()
public long getInitialDelayForPeriodicTask()
public int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object anObject)
equals in class java.lang.Object