Class ActivityTask
- All Implemented Interfaces:
Serializable
,Cloneable
Unit of work sent to an activity worker.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionclone()
boolean
The unique ID of the task.The type of this activity task.getInput()
The inputs provided when the activity task was scheduled.The ID of theActivityTaskStarted
event recorded in the history.The opaque string used as a handle on the task.The workflow execution that started this activity task.int
hashCode()
void
setActivityId
(String activityId) The unique ID of the task.void
setActivityType
(ActivityType activityType) The type of this activity task.void
The inputs provided when the activity task was scheduled.void
setStartedEventId
(Long startedEventId) The ID of theActivityTaskStarted
event recorded in the history.void
setTaskToken
(String taskToken) The opaque string used as a handle on the task.void
setWorkflowExecution
(WorkflowExecution workflowExecution) The workflow execution that started this activity task.toString()
Returns a string representation of this object; useful for testing and debugging.withActivityId
(String activityId) The unique ID of the task.withActivityType
(ActivityType activityType) The type of this activity task.The inputs provided when the activity task was scheduled.withStartedEventId
(Long startedEventId) The ID of theActivityTaskStarted
event recorded in the history.withTaskToken
(String taskToken) The opaque string used as a handle on the task.withWorkflowExecution
(WorkflowExecution workflowExecution) The workflow execution that started this activity task.
-
Constructor Details
-
ActivityTask
public ActivityTask()
-
-
Method Details
-
setTaskToken
The opaque string used as a handle on the task. This token is used by workers to communicate progress and response information back to the system about the task.
- Parameters:
taskToken
- The opaque string used as a handle on the task. This token is used by workers to communicate progress and response information back to the system about the task.
-
getTaskToken
The opaque string used as a handle on the task. This token is used by workers to communicate progress and response information back to the system about the task.
- Returns:
- The opaque string used as a handle on the task. This token is used by workers to communicate progress and response information back to the system about the task.
-
withTaskToken
The opaque string used as a handle on the task. This token is used by workers to communicate progress and response information back to the system about the task.
- Parameters:
taskToken
- The opaque string used as a handle on the task. This token is used by workers to communicate progress and response information back to the system about the task.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setActivityId
The unique ID of the task.
- Parameters:
activityId
- The unique ID of the task.
-
getActivityId
The unique ID of the task.
- Returns:
- The unique ID of the task.
-
withActivityId
The unique ID of the task.
- Parameters:
activityId
- The unique ID of the task.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setStartedEventId
The ID of the
ActivityTaskStarted
event recorded in the history.- Parameters:
startedEventId
- The ID of theActivityTaskStarted
event recorded in the history.
-
getStartedEventId
The ID of the
ActivityTaskStarted
event recorded in the history.- Returns:
- The ID of the
ActivityTaskStarted
event recorded in the history.
-
withStartedEventId
The ID of the
ActivityTaskStarted
event recorded in the history.- Parameters:
startedEventId
- The ID of theActivityTaskStarted
event recorded in the history.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setWorkflowExecution
The workflow execution that started this activity task.
- Parameters:
workflowExecution
- The workflow execution that started this activity task.
-
getWorkflowExecution
The workflow execution that started this activity task.
- Returns:
- The workflow execution that started this activity task.
-
withWorkflowExecution
The workflow execution that started this activity task.
- Parameters:
workflowExecution
- The workflow execution that started this activity task.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setActivityType
The type of this activity task.
- Parameters:
activityType
- The type of this activity task.
-
getActivityType
The type of this activity task.
- Returns:
- The type of this activity task.
-
withActivityType
The type of this activity task.
- Parameters:
activityType
- The type of this activity task.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
setInput
The inputs provided when the activity task was scheduled. The form of the input is user defined and should be meaningful to the activity implementation.
- Parameters:
input
- The inputs provided when the activity task was scheduled. The form of the input is user defined and should be meaningful to the activity implementation.
-
getInput
The inputs provided when the activity task was scheduled. The form of the input is user defined and should be meaningful to the activity implementation.
- Returns:
- The inputs provided when the activity task was scheduled. The form of the input is user defined and should be meaningful to the activity implementation.
-
withInput
The inputs provided when the activity task was scheduled. The form of the input is user defined and should be meaningful to the activity implementation.
- Parameters:
input
- The inputs provided when the activity task was scheduled. The form of the input is user defined and should be meaningful to the activity implementation.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
toString
Returns a string representation of this object; useful for testing and debugging. -
equals
-
hashCode
public int hashCode() -
clone
-