@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof DescribeStackSetResult == false) return false; DescribeStackSetResult other = (DescribeStackSetResult) obj; if (other.getStackSet() == null ^ this.getStackSet() == null) return false; if (other.getStackSet() != null && other.getStackSet().equals(this.getStackSet()) == false) return false; return true; }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getStackSet() == null) ? 0 : getStackSet().hashCode()); return hashCode; }
/** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getStackSet() != null) sb.append("StackSet: ").append(getStackSet()); sb.append("}"); return sb.toString(); }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof DescribeStackSetResult == false) return false; DescribeStackSetResult other = (DescribeStackSetResult) obj; if (other.getStackSet() == null ^ this.getStackSet() == null) return false; if (other.getStackSet() != null && other.getStackSet().equals(this.getStackSet()) == false) return false; return true; }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getStackSet() == null) ? 0 : getStackSet().hashCode()); return hashCode; }
/** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getStackSet() != null) sb.append("StackSet: ").append(getStackSet()); sb.append("}"); return sb.toString(); }
DescribeStackSetResult waitForStackState(StackSetStatus expectedStatus, Duration 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 { Thread.sleep(pollInterval.toMillis()); return waitForStackState(expectedStatus, pollInterval); } }