Class TaskSummary

All Implemented Interfaces:
LocalId, Serializable
Direct Known Subclasses:
TaskDetails

public class TaskSummary extends TaskProperties
Holds a high-level summary for a task.
See Also:
  • Field Details

    • TASK_STATUS_ASSIGNED

      public static final Integer TASK_STATUS_ASSIGNED
      A status indicating that a task's initialization is complete and the task is ready to be accepted, but no user has accepted it yet.
    • TASK_STATUS_ACCEPTED

      public static final Integer TASK_STATUS_ACCEPTED
      A task receives this status when it is accepted by a user.
    • TASK_STATUS_COMPLETED

      public static final Integer TASK_STATUS_COMPLETED
      A final status indicating that a task has been completed.
    • TASK_STATUS_NOT_STARTED

      public static final Integer TASK_STATUS_NOT_STARTED
      A status indicating that a task has been created but its initialization has not yet begun. Spawned tasks that execute sequentially have this status until the preceding task in the sequence is completed.
    • TASK_STATUS_CANCELLED

      public static final Integer TASK_STATUS_CANCELLED
      A final status indicating that a task has been canceled.
    • TASK_STATUS_PAUSED

      public static final Integer TASK_STATUS_PAUSED
      A status indicating that a task has been paused.
    • TASK_STATUS_UNATTENDED

      public static final Integer TASK_STATUS_UNATTENDED
      A status indicating that an unattended task has finished initialization and is either executing or about to be executed.
    • TASK_STATUS_ABORTED

      @Deprecated public static final Integer TASK_STATUS_ABORTED
      Deprecated.
      This status is not used.
    • TASK_STATUS_PAUSED_BY_EXCEPTION

      public static final Integer TASK_STATUS_PAUSED_BY_EXCEPTION
      A status indicating that a task has been paused by exception.
    • TASK_STATUS_SUBMITTED

      public static final Integer TASK_STATUS_SUBMITTED
      A status indicating that a legacy web service activity has been submitted.
    • TASK_STATUS_RUNNING

      public static final Integer TASK_STATUS_RUNNING
      A status indicating that a legacy web service activity is running.
    • TASK_STATUS_ERROR

      public static final Integer TASK_STATUS_ERROR
      A status indicating that an error has occurred during execution of a legacy web service activity.
    • TASK_STATUS_SKIPPED

      public static final Integer TASK_STATUS_SKIPPED
      A final status indicating that a task has been skipped. A task is skipped when its exception flow is taken.
    • SORT_BY_NAME

      public static final Integer SORT_BY_NAME
    • SORT_BY_STATUS

      public static final Integer SORT_BY_STATUS
    • SORT_BY_PRIORITY_NAME

      public static final Integer SORT_BY_PRIORITY_NAME
    • SORT_BY_ASSIGNED_TIME

      public static final Integer SORT_BY_ASSIGNED_TIME
    • SORT_BY_ACCEPTED_TIME

      public static final Integer SORT_BY_ACCEPTED_TIME
    • SORT_BY_ELAPSED_MILLISECONDS

      public static final Integer SORT_BY_ELAPSED_MILLISECONDS
    • SORT_BY_COMPLETED_TIME

      public static final Integer SORT_BY_COMPLETED_TIME
    • SORT_BY_PROCESS_NAME

      public static final Integer SORT_BY_PROCESS_NAME
    • SORT_BY_PROCESS_INITIATOR

      public static final Integer SORT_BY_PROCESS_INITIATOR
    • SORT_BY_ID

      public static final Integer SORT_BY_ID
    • SORT_BY_DESCRIPTION

      public static final Integer SORT_BY_DESCRIPTION
    • SORT_BY_OWNERS

      public static final Integer SORT_BY_OWNERS
    • SORT_BY_PROCESSID

      public static final Integer SORT_BY_PROCESSID
    • SORT_BY_ACCEPTMODE

      public static final Integer SORT_BY_ACCEPTMODE
    • SORT_BY_ONE_USER_ASSIGNED

      public static final Integer SORT_BY_ONE_USER_ASSIGNED
    • SORT_BY_ELAPSED

      @Deprecated public static final Integer SORT_BY_ELAPSED
      Deprecated.
    • SORT_BY_PRIORITY_ID

      @Deprecated public static final Integer SORT_BY_PRIORITY_ID
      Deprecated.
      Use SORT_BY_PRIORITY_NAME instead, which produces the same results.
  • Constructor Details

    • TaskSummary

      public TaskSummary()
  • Method Details

    • getProcessStatus

      public int getProcessStatus()
      Returns the status of the process that this task is part of; using this property could result in race conditions if the process status is updated after the task summary object is retrieved.
    • setProcessStatus

      public void setProcessStatus(int processStatus_)
    • getException

      public ProcessException getException()
      If the task is paused by exception, returns the exception on the task; otherwise, returns null.
    • setException

      public void setException(ProcessException exception_)
    • getChildProcessId

      public Long getChildProcessId()
      If this task is a Sub-Process or Linked-Process node, returns the id of the child process that this task references; otherwise returns null.
    • setChildProcessId

      public void setChildProcessId(Long childProcessId_)
    • getAcceptedTime

      public Timestamp getAcceptedTime()
      Returns the time at which the task was accepted or null if it has not yet been accepted.
    • setAcceptedTime

      public void setAcceptedTime(Timestamp time_)
    • getAcceptMode

      public Integer getAcceptMode()
      Returns the accept mode of the task: 0 is Auto Accept Always, 1 is Auto Accept When Assigned, and 2 is Manually Accept Always.
    • setAcceptMode

      public void setAcceptMode(Integer mode_)
    • getAssignedTime

      public Timestamp getAssignedTime()
      Returns the time at which the task was assigned or null if it has not yet been assigned.
    • setAssignedTime

      public void setAssignedTime(Timestamp time_)
    • getCompletedTime

      public Timestamp getCompletedTime()
      Returns the time at which the task was completed, or null if it has not yet been completed.
    • setCompletedTime

      public void setCompletedTime(Timestamp time_)
    • getElapsedMilliseconds

      @Deprecated public Long getElapsedMilliseconds()
      Deprecated.
      Use getElapsed() instead.
      Returns the amount of time (in ms) since the task was started.
    • setElapsedMilliseconds

      @Deprecated public void setElapsedMilliseconds(Long milliseconds_)
      Deprecated.
      Use #setElapsed() instead.
    • getElapsed

      public Double getElapsed()
      Returns the amount of time (in days) since the task was started.
    • setElapsed

      public void setElapsed(Double elapsed_)
    • getOwners

      public String[] getOwners()
      Returns the usernames of the owners of the task.
    • setOwners

      public void setOwners(String[] owners_)
    • getProcessId

      public Long getProcessId()
      Returns the id of the process that the task is part of.
    • setProcessId

      public void setProcessId(Long id_)
    • getProcessName

      public String getProcessName()
      Returns the name of the process that this task is part of.
    • setProcessName

      public void setProcessName(String name_)
    • getStatus

      public Integer getStatus()
      Returns the status of the task, which is one of the TASK_STATUS_XXX constants defined by this class.
    • setStatus

      public void setStatus(Integer status_)
    • getProcessInitiator

      public String getProcessInitiator()
      Returns the username of the initiator of the process that this task is part of.
    • setProcessInitiator

      public void setProcessInitiator(String initiator_)
    • isOneUserAssigned

      public boolean isOneUserAssigned()
      Returns true if the task is assigned to exactly one user, and false otherwise.
    • setOneUserAssigned

      public void setOneUserAssigned(boolean oneUserAssigned_)
    • getIsAttended

      public boolean getIsAttended()
      Returns true if the task is attended, and false otherwise
    • setIsAttended

      public void setIsAttended(boolean isAttended_)
    • isCompleted

      public boolean isCompleted()
      Returns true if the task has been completed, and false otherwise.
    • getAssignees

      public Assignment.Assignee[] getAssignees()
      Returns the users/groups that the task is assigned to.
    • setAssignees

      public void setAssignees(Assignment.Assignee[] assignees_)
    • getPermissions

      public NodePermissions getPermissions()
      Return the permissions for the task.
    • setPermissions

      public void setPermissions(NodePermissions permissions_)
    • getStatusBy

      public String getStatusBy()
      If the task is paused or cancelled, returns the username of the user who paused/cancelled the task; otherwise returns null.
    • setStatusBy

      public void setStatusBy(String statusBy_)
    • getStatusTime

      public Timestamp getStatusTime()
      If the task is paused or cancelled, returns the time at which the task was paused/cancelled; otherwise returns null.
    • setStatusTime

      public void setStatusTime(Timestamp time_)
    • getTemplateId

      public Long getTemplateId()
      Returns the id of the node (in the process model for the process that the task is part of) that is the "template" for the task.
    • setTemplateId

      public void setTemplateId(Long id_)
    • isMutablePriority

      public boolean isMutablePriority()
      Returns true if the priority of this task is mutable (ie can be changed), and false otherwise.
    • setMutablePriority

      public void setMutablePriority(boolean mutablePriority_)
    • getFavorite

      public boolean getFavorite()
    • setFavorite

      public void setFavorite(boolean favorite_)
    • getProcessDeadline

      public Timestamp getProcessDeadline()
    • setProcessDeadline

      public void setProcessDeadline(Timestamp processDeadline_)
    • getTaskDeadline

      public Timestamp getTaskDeadline()
    • setTaskDeadline

      public void setTaskDeadline(Timestamp taskDeadline_)
    • isInChain

      public boolean isInChain()
    • setInChain

      public void setInChain(boolean inChain_)
    • isAllowInlineApproval

      public boolean isAllowInlineApproval()
      Gets whether the task's form supports inline approval in the context user's effective locale. This corresponds to the FormConfig.TASK_ALLOW_INLINE_APPROVAL flag.
      Returns:
      whether the task's form supports inline approval
      See Also:
    • setAllowInlineApproval

      public void setAllowInlineApproval(boolean allowInlineApproval)
      The form's inline approval status is set by the system when this bean is returned. Calling this method has no effect.
      Parameters:
      allowInlineApproval - whether the task's form supports inline approval in the context user's effective locale
      See Also:
    • isMobileEnabled

      public boolean isMobileEnabled()
      Gets whether the task's form is mobile enabled in the context user's effective locale. This corresponds to the FormConfig.FORM_IS_MOBILE_ENABLED flag.
      Returns:
      whether the task's form is mobile enabled
      See Also:
    • setMobileEnabled

      public void setMobileEnabled(boolean isMobileEnabled)
      The form's mobile enabled status is set by the system when this bean is returned. Calling this method has no effect.
      Parameters:
      isMobileEnabled - whether the task's form is mobile enabled in the context user's effective locale
      See Also:
    • getFormCapability

      public int getFormCapability()
      Get the form capabilities required for this task (FormConfig CAPABILITY_* constants merged together via bitwise 'or'). This is available only for TaskSummary objects returned by ProcessAnalyticsService (e.g., via getMyTasks). Example: If a form requires UI Expression capabilities, then it returns FormConfig.CAPABILITY_ALLOW_TYPE_UI_EXPRESSION.
      Returns:
      form capabilities required
      See Also:
    • setFormCapability

      public void setFormCapability(int formCapability)
      Set the form capabilities required for this task (FormConfig CAPABILITY_* constants merged together via bitwise 'or').
      Parameters:
      formCapability - bit vector
      See Also: