Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  /*
   * Copyright 2010-2015 Amazon.com, Inc. or its affiliates. All Rights Reserved.
   * 
   * Licensed under the Apache License, Version 2.0 (the "License").
   * You may not use this file except in compliance with the License.
   * A copy of the License is located at
   * 
   *  http://aws.amazon.com/apache2.0
   * 
  * or in the "license" file accompanying this file. This file is distributed
  * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
  * express or implied. See the License for the specific language governing
  * permissions and limitations under the License.
  */
 package com.amazonaws.services.simpleworkflow.model;
 

The configuration settings for a workflow execution including timeout values, tasklist etc. These configuration settings are determined from the defaults specified when registering the workflow type and those specified when starting the workflow execution.

 
 public class WorkflowExecutionConfiguration implements SerializableCloneable {

    
The maximum duration allowed for decision tasks for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

Constraints:
Length: 1 - 8

 
     private String taskStartToCloseTimeout;

    
The total duration for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

Constraints:
Length: 1 - 8

 
     private String executionStartToCloseTimeout;

    
The task list used for the decision tasks generated for this workflow execution.
 
     private TaskList taskList;

    
The priority assigned to decision tasks for this workflow execution. Valid values are integers that range from Java's Integer.MIN_VALUE (-2147483648) to Integer.MAX_VALUE (2147483647). Higher numbers indicate higher priority.

For more information about setting task priority, see Setting Task Priority in the Amazon Simple Workflow Developer Guide.

Constraints:
Length: 0 - 11

 
     private String taskPriority;

    
The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.

Constraints:
Allowed Values: TERMINATE, REQUEST_CANCEL, ABANDON

 
     private String childPolicy;

    
The maximum duration allowed for decision tasks for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

Constraints:
Length: 1 - 8

Returns:
The maximum duration allowed for decision tasks for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

        return ;
    }
    
    
The maximum duration allowed for decision tasks for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

Constraints:
Length: 1 - 8

Parameters:
taskStartToCloseTimeout The maximum duration allowed for decision tasks for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

    public void setTaskStartToCloseTimeout(String taskStartToCloseTimeout) {
        this. = taskStartToCloseTimeout;
    }
    
    
The maximum duration allowed for decision tasks for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Length: 1 - 8

Parameters:
taskStartToCloseTimeout The maximum duration allowed for decision tasks for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

Returns:
A reference to this updated object so that method calls can be chained together.
    public WorkflowExecutionConfiguration withTaskStartToCloseTimeout(String taskStartToCloseTimeout) {
        this. = taskStartToCloseTimeout;
        return this;
    }

    
The total duration for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

Constraints:
Length: 1 - 8

Returns:
The total duration for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

        return ;
    }
    
    
The total duration for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

Constraints:
Length: 1 - 8

Parameters:
executionStartToCloseTimeout The total duration for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

    public void setExecutionStartToCloseTimeout(String executionStartToCloseTimeout) {
        this. = executionStartToCloseTimeout;
    }
    
    
The total duration for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Length: 1 - 8

Parameters:
executionStartToCloseTimeout The total duration for this workflow execution.

The duration is specified in seconds; an integer greater than or equal to 0. The value "NONE" can be used to specify unlimited duration.

Returns:
A reference to this updated object so that method calls can be chained together.
    public WorkflowExecutionConfiguration withExecutionStartToCloseTimeout(String executionStartToCloseTimeout) {
        this. = executionStartToCloseTimeout;
        return this;
    }

    
The task list used for the decision tasks generated for this workflow execution.

Returns:
The task list used for the decision tasks generated for this workflow execution.
    public TaskList getTaskList() {
        return ;
    }
    
    
The task list used for the decision tasks generated for this workflow execution.

Parameters:
taskList The task list used for the decision tasks generated for this workflow execution.
    public void setTaskList(TaskList taskList) {
        this. = taskList;
    }
    
    
The task list used for the decision tasks generated for this workflow execution.

Returns a reference to this object so that method calls can be chained together.

Parameters:
taskList The task list used for the decision tasks generated for this workflow execution.
Returns:
A reference to this updated object so that method calls can be chained together.
        this. = taskList;
        return this;
    }

    
The priority assigned to decision tasks for this workflow execution. Valid values are integers that range from Java's Integer.MIN_VALUE (-2147483648) to Integer.MAX_VALUE (2147483647). Higher numbers indicate higher priority.

For more information about setting task priority, see Setting Task Priority in the Amazon Simple Workflow Developer Guide.

Constraints:
Length: 0 - 11

Returns:
The priority assigned to decision tasks for this workflow execution. Valid values are integers that range from Java's Integer.MIN_VALUE (-2147483648) to Integer.MAX_VALUE (2147483647). Higher numbers indicate higher priority.

For more information about setting task priority, see Setting Task Priority in the Amazon Simple Workflow Developer Guide.

    public String getTaskPriority() {
        return ;
    }
    
    
The priority assigned to decision tasks for this workflow execution. Valid values are integers that range from Java's Integer.MIN_VALUE (-2147483648) to Integer.MAX_VALUE (2147483647). Higher numbers indicate higher priority.

For more information about setting task priority, see Setting Task Priority in the Amazon Simple Workflow Developer Guide.

Constraints:
Length: 0 - 11

Parameters:
taskPriority The priority assigned to decision tasks for this workflow execution. Valid values are integers that range from Java's Integer.MIN_VALUE (-2147483648) to Integer.MAX_VALUE (2147483647). Higher numbers indicate higher priority.

For more information about setting task priority, see Setting Task Priority in the Amazon Simple Workflow Developer Guide.

    public void setTaskPriority(String taskPriority) {
        this. = taskPriority;
    }
    
    
The priority assigned to decision tasks for this workflow execution. Valid values are integers that range from Java's Integer.MIN_VALUE (-2147483648) to Integer.MAX_VALUE (2147483647). Higher numbers indicate higher priority.

For more information about setting task priority, see Setting Task Priority in the Amazon Simple Workflow Developer Guide.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Length: 0 - 11

Parameters:
taskPriority The priority assigned to decision tasks for this workflow execution. Valid values are integers that range from Java's Integer.MIN_VALUE (-2147483648) to Integer.MAX_VALUE (2147483647). Higher numbers indicate higher priority.

For more information about setting task priority, see Setting Task Priority in the Amazon Simple Workflow Developer Guide.

Returns:
A reference to this updated object so that method calls can be chained together.
    public WorkflowExecutionConfiguration withTaskPriority(String taskPriority) {
        this. = taskPriority;
        return this;
    }

    
The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.

Constraints:
Allowed Values: TERMINATE, REQUEST_CANCEL, ABANDON

Returns:
The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.
See also:
ChildPolicy
    public String getChildPolicy() {
        return ;
    }
    
    
The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.

Constraints:
Allowed Values: TERMINATE, REQUEST_CANCEL, ABANDON

Parameters:
childPolicy The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.
See also:
ChildPolicy
    public void setChildPolicy(String childPolicy) {
        this. = childPolicy;
    }
    
    
The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Allowed Values: TERMINATE, REQUEST_CANCEL, ABANDON

Parameters:
childPolicy The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.
Returns:
A reference to this updated object so that method calls can be chained together.
See also:
ChildPolicy
    public WorkflowExecutionConfiguration withChildPolicy(String childPolicy) {
        this. = childPolicy;
        return this;
    }

    
The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.

Constraints:
Allowed Values: TERMINATE, REQUEST_CANCEL, ABANDON

Parameters:
childPolicy The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.
See also:
ChildPolicy
    public void setChildPolicy(ChildPolicy childPolicy) {
        this. = childPolicy.toString();
    }
    
    
The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.

Returns a reference to this object so that method calls can be chained together.

Constraints:
Allowed Values: TERMINATE, REQUEST_CANCEL, ABANDON

Parameters:
childPolicy The policy to use for the child workflow executions if this workflow execution is terminated, by calling the TerminateWorkflowExecution action explicitly or due to an expired timeout.

The supported child policies are:

  • TERMINATE: the child executions will be terminated.
  • REQUEST_CANCEL: a request to cancel will be attempted for each child execution by recording a WorkflowExecutionCancelRequested event in its history. It is up to the decider to take appropriate actions when it receives an execution history with this event.
  • ABANDON: no action will be taken. The child executions will continue to run.
Returns:
A reference to this updated object so that method calls can be chained together.
See also:
ChildPolicy
        this. = childPolicy.toString();
        return this;
    }

    
Returns a string representation of this object; useful for testing and debugging.

Returns:
A string representation of this object.
See also:
java.lang.Object.toString()
    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append("{");
        if (getTaskStartToCloseTimeout() != nullsb.append("TaskStartToCloseTimeout: " + getTaskStartToCloseTimeout() + ",");
        if (getExecutionStartToCloseTimeout() != nullsb.append("ExecutionStartToCloseTimeout: " + getExecutionStartToCloseTimeout() + ",");
        if (getTaskList() != nullsb.append("TaskList: " + getTaskList() + ",");
        if (getTaskPriority() != nullsb.append("TaskPriority: " + getTaskPriority() + ",");
        if (getChildPolicy() != nullsb.append("ChildPolicy: " + getChildPolicy() );
        sb.append("}");
        return sb.toString();
    }
    
    @Override
    public int hashCode() {
        final int prime = 31;
        int hashCode = 1;
        
        hashCode = prime * hashCode + ((getTaskStartToCloseTimeout() == null) ? 0 : getTaskStartToCloseTimeout().hashCode()); 
        hashCode = prime * hashCode + ((getExecutionStartToCloseTimeout() == null) ? 0 : getExecutionStartToCloseTimeout().hashCode()); 
        hashCode = prime * hashCode + ((getTaskList() == null) ? 0 : getTaskList().hashCode()); 
        hashCode = prime * hashCode + ((getTaskPriority() == null) ? 0 : getTaskPriority().hashCode()); 
        hashCode = prime * hashCode + ((getChildPolicy() == null) ? 0 : getChildPolicy().hashCode()); 
        return hashCode;
    }
    
    @Override
    public boolean equals(Object obj) {
        if (this == objreturn true;
        if (obj == nullreturn false;
        if (obj instanceof WorkflowExecutionConfiguration == falsereturn false;
        
        if (other.getTaskStartToCloseTimeout() == null ^ this.getTaskStartToCloseTimeout() == nullreturn false;
        if (other.getTaskStartToCloseTimeout() != null && other.getTaskStartToCloseTimeout().equals(this.getTaskStartToCloseTimeout()) == falsereturn false
        if (other.getExecutionStartToCloseTimeout() == null ^ this.getExecutionStartToCloseTimeout() == nullreturn false;
        if (other.getExecutionStartToCloseTimeout() != null && other.getExecutionStartToCloseTimeout().equals(this.getExecutionStartToCloseTimeout()) == falsereturn false
        if (other.getTaskList() == null ^ this.getTaskList() == nullreturn false;
        if (other.getTaskList() != null && other.getTaskList().equals(this.getTaskList()) == falsereturn false
        if (other.getTaskPriority() == null ^ this.getTaskPriority() == nullreturn false;
        if (other.getTaskPriority() != null && other.getTaskPriority().equals(this.getTaskPriority()) == falsereturn false
        if (other.getChildPolicy() == null ^ this.getChildPolicy() == nullreturn false;
        if (other.getChildPolicy() != null && other.getChildPolicy().equals(this.getChildPolicy()) == falsereturn false
        return true;
    }
    
    @Override
        try {
            return (WorkflowExecutionConfigurationsuper.clone();
        
        } catch (CloneNotSupportedException e) {
            throw new IllegalStateException(
                    "Got a CloneNotSupportedException from Object.clone() "
                    + "even though we're Cloneable!",
                    e);
        }
        
    }
}
    
New to GrepCode? Check out our FAQ X