public class DecisionTask extends Object implements Serializable
A structure that represents a decision task. Decision tasks are sent to deciders in order for them to make decisions.
Constructor and Description |
---|
DecisionTask() |
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj) |
List<HistoryEvent> |
getEvents()
A paginated list of history events of the workflow execution.
|
String |
getNextPageToken()
Returns a value if the results are paginated.
|
Long |
getPreviousStartedEventId()
The id of the DecisionTaskStarted event of the previous decision task
of this workflow execution that was processed by the decider.
|
Long |
getStartedEventId()
The id of the
DecisionTaskStarted event recorded in the
history. |
String |
getTaskToken()
The opaque string used as a handle on the task.
|
WorkflowExecution |
getWorkflowExecution()
The workflow execution for which this decision task was created.
|
WorkflowType |
getWorkflowType()
The type of the workflow execution for which this decision task was
created.
|
int |
hashCode() |
void |
setEvents(Collection<HistoryEvent> events)
A paginated list of history events of the workflow execution.
|
void |
setNextPageToken(String nextPageToken)
Returns a value if the results are paginated.
|
void |
setPreviousStartedEventId(Long previousStartedEventId)
The id of the DecisionTaskStarted event of the previous decision task
of this workflow execution that was processed by the decider.
|
void |
setStartedEventId(Long startedEventId)
The id of the
DecisionTaskStarted 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 for which this decision task was created.
|
void |
setWorkflowType(WorkflowType workflowType)
The type of the workflow execution for which this decision task was
created.
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
DecisionTask |
withEvents(Collection<HistoryEvent> events)
A paginated list of history events of the workflow execution.
|
DecisionTask |
withEvents(HistoryEvent... events)
A paginated list of history events of the workflow execution.
|
DecisionTask |
withNextPageToken(String nextPageToken)
Returns a value if the results are paginated.
|
DecisionTask |
withPreviousStartedEventId(Long previousStartedEventId)
The id of the DecisionTaskStarted event of the previous decision task
of this workflow execution that was processed by the decider.
|
DecisionTask |
withStartedEventId(Long startedEventId)
The id of the
DecisionTaskStarted event recorded in the
history. |
DecisionTask |
withTaskToken(String taskToken)
The opaque string used as a handle on the task.
|
DecisionTask |
withWorkflowExecution(WorkflowExecution workflowExecution)
The workflow execution for which this decision task was created.
|
DecisionTask |
withWorkflowType(WorkflowType workflowType)
The type of the workflow execution for which this decision task was
created.
|
public String getTaskToken()
Constraints:
Length: 1 - 1024
public void setTaskToken(String taskToken)
Constraints:
Length: 1 - 1024
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.public DecisionTask withTaskToken(String taskToken)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 1 - 1024
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.public Long getStartedEventId()
DecisionTaskStarted
event recorded in the
history.DecisionTaskStarted
event recorded in the
history.public void setStartedEventId(Long startedEventId)
DecisionTaskStarted
event recorded in the
history.startedEventId
- The id of the DecisionTaskStarted
event recorded in the
history.public DecisionTask withStartedEventId(Long startedEventId)
DecisionTaskStarted
event recorded in the
history.
Returns a reference to this object so that method calls can be chained together.
startedEventId
- The id of the DecisionTaskStarted
event recorded in the
history.public WorkflowExecution getWorkflowExecution()
public void setWorkflowExecution(WorkflowExecution workflowExecution)
workflowExecution
- The workflow execution for which this decision task was created.public DecisionTask withWorkflowExecution(WorkflowExecution workflowExecution)
Returns a reference to this object so that method calls can be chained together.
workflowExecution
- The workflow execution for which this decision task was created.public WorkflowType getWorkflowType()
public void setWorkflowType(WorkflowType workflowType)
workflowType
- The type of the workflow execution for which this decision task was
created.public DecisionTask withWorkflowType(WorkflowType workflowType)
Returns a reference to this object so that method calls can be chained together.
workflowType
- The type of the workflow execution for which this decision task was
created.public List<HistoryEvent> getEvents()
public void setEvents(Collection<HistoryEvent> events)
events
- A paginated list of history events of the workflow execution. The
decider uses this during the processing of the decision task.public DecisionTask withEvents(HistoryEvent... events)
Returns a reference to this object so that method calls can be chained together.
events
- A paginated list of history events of the workflow execution. The
decider uses this during the processing of the decision task.public DecisionTask withEvents(Collection<HistoryEvent> events)
Returns a reference to this object so that method calls can be chained together.
events
- A paginated list of history events of the workflow execution. The
decider uses this during the processing of the decision task.public String getNextPageToken()
Constraints:
Length: 0 - 2048
public void setNextPageToken(String nextPageToken)
Constraints:
Length: 0 - 2048
nextPageToken
- Returns a value if the results are paginated. To get the next page of
results, repeat the request specifying this token and all other
arguments unchanged.public DecisionTask withNextPageToken(String nextPageToken)
Returns a reference to this object so that method calls can be chained together.
Constraints:
Length: 0 - 2048
nextPageToken
- Returns a value if the results are paginated. To get the next page of
results, repeat the request specifying this token and all other
arguments unchanged.public Long getPreviousStartedEventId()
public void setPreviousStartedEventId(Long previousStartedEventId)
previousStartedEventId
- The id of the DecisionTaskStarted event of the previous decision task
of this workflow execution that was processed by the decider. This can
be used to determine the events in the history new since the last
decision task received by the decider.public DecisionTask withPreviousStartedEventId(Long previousStartedEventId)
Returns a reference to this object so that method calls can be chained together.
previousStartedEventId
- The id of the DecisionTaskStarted event of the previous decision task
of this workflow execution that was processed by the decider. This can
be used to determine the events in the history new since the last
decision task received by the decider.public String toString()
toString
in class Object
Object.toString()
Copyright © 2015. All rights reserved.