Example usage for com.amazonaws.services.cloudformation.model StackSetStatus fromValue

List of usage examples for com.amazonaws.services.cloudformation.model StackSetStatus fromValue

Introduction

In this page you can find the example usage for com.amazonaws.services.cloudformation.model StackSetStatus fromValue.

Prototype

public static StackSetStatus fromValue(String value) 

Source Link

Document

Use this in place of valueOf.

Usage

From source file:de.taimos.pipeline.aws.cloudformation.stacksets.CloudFormationStackSet.java

License:Apache License

public DescribeStackSetResult waitForStackState(StackSetStatus expectedStatus, long pollInterval)
        throws InterruptedException {
    DescribeStackSetResult result = describe();
    this.listener.getLogger().println("stackSetId=" + result.getStackSet().getStackSetId() + " status="
            + result.getStackSet().getStatus());
    StackSetStatus currentStatus = StackSetStatus.fromValue(result.getStackSet().getStatus());
    if (currentStatus == expectedStatus) {
        this.listener.getLogger().println("Stack set operation completed successfully");
        return result;
    } else {/*from   ww w.ja v a2s  . co  m*/
        Thread.sleep(pollInterval);
        return waitForStackState(expectedStatus, pollInterval);
    }
}