Class TaskInfo
java.lang.Object
org.deltava.taskman.TaskInfo
- All Implemented Interfaces:
Serializable
,Comparable<TaskInfo>
A bean to store information about a scheduled task.
- Since:
- 1.0
- Version:
- 7.0
- Author:
- Luke
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
Compares two TaskInfo beans by comparing their next execution times and IDs.Returns the Task's class name.boolean
Returns if the Task is enabled for execution.getID()
Returns the Task ID.long
Returns the duration of the Task's last execution.Returns the Task's last execution date.getName()
Returns the Task name.int
Returns the number of times the Task has been executed.Returns the times this Task is eligible to be run.
-
Constructor Details
-
TaskInfo
Initializes the Task Information bean.- Parameters:
t
- the Task to display information about
-
-
Method Details
-
getName
-
getID
-
getClassName
-
getRunTimes
Returns the times this Task is eligible to be run.- Returns:
- a Map of interval types and values
- See Also:
-
getLastStartTime
Returns the Task's last execution date.- Returns:
- the date/time the Task was last run, or null if never
- See Also:
-
getLastRunTime
public long getLastRunTime()Returns the duration of the Task's last execution.- Returns:
- the execution time in milliseconds
- See Also:
-
getEnabled
public boolean getEnabled()Returns if the Task is enabled for execution.- Returns:
- TRUE if the Task is enabled, otherwise FALSE
-
getRunCount
public int getRunCount()Returns the number of times the Task has been executed.- Returns:
- the execution count
-
compareTo
Compares two TaskInfo beans by comparing their next execution times and IDs.- Specified by:
compareTo
in interfaceComparable<TaskInfo>
-