Enum Task.Status

java.lang.Object
java.lang.Enum<Task.Status>
xyz.euclia.jaqpotj.models.Task.Status
All Implemented Interfaces:
Serializable, Comparable<Task.Status>, java.lang.constant.Constable
Enclosing class:
Task

public static enum Task.Status
extends Enum<Task.Status>
Status of the task revealing information about the asynchronous job with which the task is related and runs on a server.
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant Description
    CANCELLED
    The task is canceled by the User.
    COMPLETED
    The task has completed execution successfully.
    ERROR
    Task execution was interrupted due to some error related with the asynchronous job, either due to a bad request by the client, an internal server error or an error related to a third remote service.
    QUEUED
    The task is created and put in an execution queue but is not running yet.
    REJECTED
    Due to large load on the server or issues related to A&A or user quota, the task was rejected for execution.
    RUNNING
    The task is still Running in the background as an asynchronous job.
  • Method Summary

    Modifier and Type Method Description
    static Task.Status valueOf​(String name)
    Returns the enum constant of this type with the specified name.
    static Task.Status[] values()
    Returns an array containing the constants of this enum type, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • RUNNING

      public static final Task.Status RUNNING
      The task is still Running in the background as an asynchronous job. This status means that the task has been submitted to the Execution Pool but has not completed yet.
    • COMPLETED

      public static final Task.Status COMPLETED
      The task has completed execution successfully. The result can be found under #resultUri and is accessible via Task.getResultUri(). The corresponding status is either 200 if the result is the URI of a created resource or 201 if it redirects to some other task (most probably on some other server)
    • CANCELLED

      public static final Task.Status CANCELLED
      The task is canceled by the User.
    • ERROR

      public static final Task.Status ERROR
      Task execution was interrupted due to some error related with the asynchronous job, either due to a bad request by the client, an internal server error or an error related to a third remote service. In such a case, the task is accompanied by an error report that provides access to details about the exceptional event.
    • REJECTED

      public static final Task.Status REJECTED
      Due to large load on the server or issues related to A&A or user quota, the task was rejected for execution.
    • QUEUED

      public static final Task.Status QUEUED
      The task is created and put in an execution queue but is not running yet. HTTP status codes of queued tasks is 202.
  • Method Details

    • values

      public static Task.Status[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static Task.Status valueOf​(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null