Interface TaskStatus


public interface TaskStatus
Created by colby.clegg on 3/30/2015.
  • Method Summary

    Modifier and Type
    Method
    Description
    double
    Returns a value, 0.0-1.0
    Returns a message that will be displayed for the current state.
    Returns an ID that refers to a single task.
    Returns the user defined name of the task
    Indicates the state of a task before it got suspended.
    Returns the time that the task started, if it is currently running (or was running), or the next time the task will run.
    Indicates the current state of the task, and to some degree, indicates how getStartTime() should be interpreted.
     
    boolean
    If true, this indicates that the task will be run exactly once.
  • Method Details

    • getId

      Long getId()
      Returns an ID that refers to a single task. The task type might be defined multiple times, and a task with this id might run multiple times, but there will never be more than one instance of it running at a time.
    • getTaskType

      TaskType getTaskType()
    • getState

      TaskState getState()
      Indicates the current state of the task, and to some degree, indicates how getStartTime() should be interpreted. If the state is not Running, but start time is in the past, then it is a one-shot task that has finished.
    • getPreviousState

      Optional<TaskState> getPreviousState()
      Indicates the state of a task before it got suspended. If this state was set, it will likely be Running, Waiting, or Scheduled.
    • getName

      String getName()
      Returns the user defined name of the task
    • getCurrentMessage

      String getCurrentMessage()
      Returns a message that will be displayed for the current state.
    • getCurrentCompletionPercent

      double getCurrentCompletionPercent()
      Returns a value, 0.0-1.0
    • getStartTime

      Date getStartTime()
      Returns the time that the task started, if it is currently running (or was running), or the next time the task will run.
    • isOneShot

      boolean isOneShot()
      If true, this indicates that the task will be run exactly once. Scheduled recurring tasks will return false.