All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.securityhub.model.AwsCloudFormationStackDetails Maven / Gradle / Ivy

Go to download

The AWS Java SDK for AWS SecurityHub module holds the client classes that are used for communicating with AWS SecurityHub Service

There is a newer version: 1.12.780
Show newest version
/*
 * Copyright 2019-2024 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.securityhub.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* Nests a stack as a resource in a top-level template. Nested stacks are stacks created as resources for another stack. *

* * @see AWS API Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class AwsCloudFormationStackDetails implements Serializable, Cloneable, StructuredPojo { /** *

* The capabilities allowed in the stack. *

*/ private java.util.List capabilities; /** *

* The time at which the stack was created. *

*/ private String creationTime; /** *

* A user-defined description associated with the stack. *

*/ private String description; /** *

* Boolean to enable or disable rollback on stack creation failures. *

*/ private Boolean disableRollback; /** *

* Information about whether a stack's actual configuration differs, or has drifted, from its expected * configuration, as defined in the stack template and any values specified as template parameters. *

*/ private AwsCloudFormationStackDriftInformationDetails driftInformation; /** *

* Whether termination protection is enabled for the stack. *

*/ private Boolean enableTerminationProtection; /** *

* The time the nested stack was last updated. This field will only be returned if the stack has been updated at * least once. *

*/ private String lastUpdatedTime; /** *

* The Amazon Resource Names (ARNs) of the Amazon SNS topic to which stack-related events are published. *

*/ private java.util.List notificationArns; /** *

* A list of output structures. *

*/ private java.util.List outputs; /** *

* The ARN of an IAM role that's associated with the stack. *

*/ private String roleArn; /** *

* Unique identifier of the stack. *

*/ private String stackId; /** *

* The name associated with the stack. *

*/ private String stackName; /** *

* Current status of the stack. *

*/ private String stackStatus; /** *

* Success or failure message associated with the stack status. *

*/ private String stackStatusReason; /** *

* The length of time, in minutes, that CloudFormation waits for the nested stack to reach the * CREATE_COMPLETE state. *

*/ private Integer timeoutInMinutes; /** *

* The capabilities allowed in the stack. *

* * @return The capabilities allowed in the stack. */ public java.util.List getCapabilities() { return capabilities; } /** *

* The capabilities allowed in the stack. *

* * @param capabilities * The capabilities allowed in the stack. */ public void setCapabilities(java.util.Collection capabilities) { if (capabilities == null) { this.capabilities = null; return; } this.capabilities = new java.util.ArrayList(capabilities); } /** *

* The capabilities allowed in the stack. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setCapabilities(java.util.Collection)} or {@link #withCapabilities(java.util.Collection)} if you want to * override the existing values. *

* * @param capabilities * The capabilities allowed in the stack. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withCapabilities(String... capabilities) { if (this.capabilities == null) { setCapabilities(new java.util.ArrayList(capabilities.length)); } for (String ele : capabilities) { this.capabilities.add(ele); } return this; } /** *

* The capabilities allowed in the stack. *

* * @param capabilities * The capabilities allowed in the stack. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withCapabilities(java.util.Collection capabilities) { setCapabilities(capabilities); return this; } /** *

* The time at which the stack was created. *

* * @param creationTime * The time at which the stack was created. */ public void setCreationTime(String creationTime) { this.creationTime = creationTime; } /** *

* The time at which the stack was created. *

* * @return The time at which the stack was created. */ public String getCreationTime() { return this.creationTime; } /** *

* The time at which the stack was created. *

* * @param creationTime * The time at which the stack was created. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withCreationTime(String creationTime) { setCreationTime(creationTime); return this; } /** *

* A user-defined description associated with the stack. *

* * @param description * A user-defined description associated with the stack. */ public void setDescription(String description) { this.description = description; } /** *

* A user-defined description associated with the stack. *

* * @return A user-defined description associated with the stack. */ public String getDescription() { return this.description; } /** *

* A user-defined description associated with the stack. *

* * @param description * A user-defined description associated with the stack. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withDescription(String description) { setDescription(description); return this; } /** *

* Boolean to enable or disable rollback on stack creation failures. *

* * @param disableRollback * Boolean to enable or disable rollback on stack creation failures. */ public void setDisableRollback(Boolean disableRollback) { this.disableRollback = disableRollback; } /** *

* Boolean to enable or disable rollback on stack creation failures. *

* * @return Boolean to enable or disable rollback on stack creation failures. */ public Boolean getDisableRollback() { return this.disableRollback; } /** *

* Boolean to enable or disable rollback on stack creation failures. *

* * @param disableRollback * Boolean to enable or disable rollback on stack creation failures. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withDisableRollback(Boolean disableRollback) { setDisableRollback(disableRollback); return this; } /** *

* Boolean to enable or disable rollback on stack creation failures. *

* * @return Boolean to enable or disable rollback on stack creation failures. */ public Boolean isDisableRollback() { return this.disableRollback; } /** *

* Information about whether a stack's actual configuration differs, or has drifted, from its expected * configuration, as defined in the stack template and any values specified as template parameters. *

* * @param driftInformation * Information about whether a stack's actual configuration differs, or has drifted, from its expected * configuration, as defined in the stack template and any values specified as template parameters. */ public void setDriftInformation(AwsCloudFormationStackDriftInformationDetails driftInformation) { this.driftInformation = driftInformation; } /** *

* Information about whether a stack's actual configuration differs, or has drifted, from its expected * configuration, as defined in the stack template and any values specified as template parameters. *

* * @return Information about whether a stack's actual configuration differs, or has drifted, from its expected * configuration, as defined in the stack template and any values specified as template parameters. */ public AwsCloudFormationStackDriftInformationDetails getDriftInformation() { return this.driftInformation; } /** *

* Information about whether a stack's actual configuration differs, or has drifted, from its expected * configuration, as defined in the stack template and any values specified as template parameters. *

* * @param driftInformation * Information about whether a stack's actual configuration differs, or has drifted, from its expected * configuration, as defined in the stack template and any values specified as template parameters. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withDriftInformation(AwsCloudFormationStackDriftInformationDetails driftInformation) { setDriftInformation(driftInformation); return this; } /** *

* Whether termination protection is enabled for the stack. *

* * @param enableTerminationProtection * Whether termination protection is enabled for the stack. */ public void setEnableTerminationProtection(Boolean enableTerminationProtection) { this.enableTerminationProtection = enableTerminationProtection; } /** *

* Whether termination protection is enabled for the stack. *

* * @return Whether termination protection is enabled for the stack. */ public Boolean getEnableTerminationProtection() { return this.enableTerminationProtection; } /** *

* Whether termination protection is enabled for the stack. *

* * @param enableTerminationProtection * Whether termination protection is enabled for the stack. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withEnableTerminationProtection(Boolean enableTerminationProtection) { setEnableTerminationProtection(enableTerminationProtection); return this; } /** *

* Whether termination protection is enabled for the stack. *

* * @return Whether termination protection is enabled for the stack. */ public Boolean isEnableTerminationProtection() { return this.enableTerminationProtection; } /** *

* The time the nested stack was last updated. This field will only be returned if the stack has been updated at * least once. *

* * @param lastUpdatedTime * The time the nested stack was last updated. This field will only be returned if the stack has been updated * at least once. */ public void setLastUpdatedTime(String lastUpdatedTime) { this.lastUpdatedTime = lastUpdatedTime; } /** *

* The time the nested stack was last updated. This field will only be returned if the stack has been updated at * least once. *

* * @return The time the nested stack was last updated. This field will only be returned if the stack has been * updated at least once. */ public String getLastUpdatedTime() { return this.lastUpdatedTime; } /** *

* The time the nested stack was last updated. This field will only be returned if the stack has been updated at * least once. *

* * @param lastUpdatedTime * The time the nested stack was last updated. This field will only be returned if the stack has been updated * at least once. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withLastUpdatedTime(String lastUpdatedTime) { setLastUpdatedTime(lastUpdatedTime); return this; } /** *

* The Amazon Resource Names (ARNs) of the Amazon SNS topic to which stack-related events are published. *

* * @return The Amazon Resource Names (ARNs) of the Amazon SNS topic to which stack-related events are published. */ public java.util.List getNotificationArns() { return notificationArns; } /** *

* The Amazon Resource Names (ARNs) of the Amazon SNS topic to which stack-related events are published. *

* * @param notificationArns * The Amazon Resource Names (ARNs) of the Amazon SNS topic to which stack-related events are published. */ public void setNotificationArns(java.util.Collection notificationArns) { if (notificationArns == null) { this.notificationArns = null; return; } this.notificationArns = new java.util.ArrayList(notificationArns); } /** *

* The Amazon Resource Names (ARNs) of the Amazon SNS topic to which stack-related events are published. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setNotificationArns(java.util.Collection)} or {@link #withNotificationArns(java.util.Collection)} if you * want to override the existing values. *

* * @param notificationArns * The Amazon Resource Names (ARNs) of the Amazon SNS topic to which stack-related events are published. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withNotificationArns(String... notificationArns) { if (this.notificationArns == null) { setNotificationArns(new java.util.ArrayList(notificationArns.length)); } for (String ele : notificationArns) { this.notificationArns.add(ele); } return this; } /** *

* The Amazon Resource Names (ARNs) of the Amazon SNS topic to which stack-related events are published. *

* * @param notificationArns * The Amazon Resource Names (ARNs) of the Amazon SNS topic to which stack-related events are published. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withNotificationArns(java.util.Collection notificationArns) { setNotificationArns(notificationArns); return this; } /** *

* A list of output structures. *

* * @return A list of output structures. */ public java.util.List getOutputs() { return outputs; } /** *

* A list of output structures. *

* * @param outputs * A list of output structures. */ public void setOutputs(java.util.Collection outputs) { if (outputs == null) { this.outputs = null; return; } this.outputs = new java.util.ArrayList(outputs); } /** *

* A list of output structures. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setOutputs(java.util.Collection)} or {@link #withOutputs(java.util.Collection)} if you want to override * the existing values. *

* * @param outputs * A list of output structures. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withOutputs(AwsCloudFormationStackOutputsDetails... outputs) { if (this.outputs == null) { setOutputs(new java.util.ArrayList(outputs.length)); } for (AwsCloudFormationStackOutputsDetails ele : outputs) { this.outputs.add(ele); } return this; } /** *

* A list of output structures. *

* * @param outputs * A list of output structures. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withOutputs(java.util.Collection outputs) { setOutputs(outputs); return this; } /** *

* The ARN of an IAM role that's associated with the stack. *

* * @param roleArn * The ARN of an IAM role that's associated with the stack. */ public void setRoleArn(String roleArn) { this.roleArn = roleArn; } /** *

* The ARN of an IAM role that's associated with the stack. *

* * @return The ARN of an IAM role that's associated with the stack. */ public String getRoleArn() { return this.roleArn; } /** *

* The ARN of an IAM role that's associated with the stack. *

* * @param roleArn * The ARN of an IAM role that's associated with the stack. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withRoleArn(String roleArn) { setRoleArn(roleArn); return this; } /** *

* Unique identifier of the stack. *

* * @param stackId * Unique identifier of the stack. */ public void setStackId(String stackId) { this.stackId = stackId; } /** *

* Unique identifier of the stack. *

* * @return Unique identifier of the stack. */ public String getStackId() { return this.stackId; } /** *

* Unique identifier of the stack. *

* * @param stackId * Unique identifier of the stack. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withStackId(String stackId) { setStackId(stackId); return this; } /** *

* The name associated with the stack. *

* * @param stackName * The name associated with the stack. */ public void setStackName(String stackName) { this.stackName = stackName; } /** *

* The name associated with the stack. *

* * @return The name associated with the stack. */ public String getStackName() { return this.stackName; } /** *

* The name associated with the stack. *

* * @param stackName * The name associated with the stack. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withStackName(String stackName) { setStackName(stackName); return this; } /** *

* Current status of the stack. *

* * @param stackStatus * Current status of the stack. */ public void setStackStatus(String stackStatus) { this.stackStatus = stackStatus; } /** *

* Current status of the stack. *

* * @return Current status of the stack. */ public String getStackStatus() { return this.stackStatus; } /** *

* Current status of the stack. *

* * @param stackStatus * Current status of the stack. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withStackStatus(String stackStatus) { setStackStatus(stackStatus); return this; } /** *

* Success or failure message associated with the stack status. *

* * @param stackStatusReason * Success or failure message associated with the stack status. */ public void setStackStatusReason(String stackStatusReason) { this.stackStatusReason = stackStatusReason; } /** *

* Success or failure message associated with the stack status. *

* * @return Success or failure message associated with the stack status. */ public String getStackStatusReason() { return this.stackStatusReason; } /** *

* Success or failure message associated with the stack status. *

* * @param stackStatusReason * Success or failure message associated with the stack status. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withStackStatusReason(String stackStatusReason) { setStackStatusReason(stackStatusReason); return this; } /** *

* The length of time, in minutes, that CloudFormation waits for the nested stack to reach the * CREATE_COMPLETE state. *

* * @param timeoutInMinutes * The length of time, in minutes, that CloudFormation waits for the nested stack to reach the * CREATE_COMPLETE state. */ public void setTimeoutInMinutes(Integer timeoutInMinutes) { this.timeoutInMinutes = timeoutInMinutes; } /** *

* The length of time, in minutes, that CloudFormation waits for the nested stack to reach the * CREATE_COMPLETE state. *

* * @return The length of time, in minutes, that CloudFormation waits for the nested stack to reach the * CREATE_COMPLETE state. */ public Integer getTimeoutInMinutes() { return this.timeoutInMinutes; } /** *

* The length of time, in minutes, that CloudFormation waits for the nested stack to reach the * CREATE_COMPLETE state. *

* * @param timeoutInMinutes * The length of time, in minutes, that CloudFormation waits for the nested stack to reach the * CREATE_COMPLETE state. * @return Returns a reference to this object so that method calls can be chained together. */ public AwsCloudFormationStackDetails withTimeoutInMinutes(Integer timeoutInMinutes) { setTimeoutInMinutes(timeoutInMinutes); return this; } /** * 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 (getCapabilities() != null) sb.append("Capabilities: ").append(getCapabilities()).append(","); if (getCreationTime() != null) sb.append("CreationTime: ").append(getCreationTime()).append(","); if (getDescription() != null) sb.append("Description: ").append(getDescription()).append(","); if (getDisableRollback() != null) sb.append("DisableRollback: ").append(getDisableRollback()).append(","); if (getDriftInformation() != null) sb.append("DriftInformation: ").append(getDriftInformation()).append(","); if (getEnableTerminationProtection() != null) sb.append("EnableTerminationProtection: ").append(getEnableTerminationProtection()).append(","); if (getLastUpdatedTime() != null) sb.append("LastUpdatedTime: ").append(getLastUpdatedTime()).append(","); if (getNotificationArns() != null) sb.append("NotificationArns: ").append(getNotificationArns()).append(","); if (getOutputs() != null) sb.append("Outputs: ").append(getOutputs()).append(","); if (getRoleArn() != null) sb.append("RoleArn: ").append(getRoleArn()).append(","); if (getStackId() != null) sb.append("StackId: ").append(getStackId()).append(","); if (getStackName() != null) sb.append("StackName: ").append(getStackName()).append(","); if (getStackStatus() != null) sb.append("StackStatus: ").append(getStackStatus()).append(","); if (getStackStatusReason() != null) sb.append("StackStatusReason: ").append(getStackStatusReason()).append(","); if (getTimeoutInMinutes() != null) sb.append("TimeoutInMinutes: ").append(getTimeoutInMinutes()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof AwsCloudFormationStackDetails == false) return false; AwsCloudFormationStackDetails other = (AwsCloudFormationStackDetails) obj; if (other.getCapabilities() == null ^ this.getCapabilities() == null) return false; if (other.getCapabilities() != null && other.getCapabilities().equals(this.getCapabilities()) == false) return false; if (other.getCreationTime() == null ^ this.getCreationTime() == null) return false; if (other.getCreationTime() != null && other.getCreationTime().equals(this.getCreationTime()) == false) return false; if (other.getDescription() == null ^ this.getDescription() == null) return false; if (other.getDescription() != null && other.getDescription().equals(this.getDescription()) == false) return false; if (other.getDisableRollback() == null ^ this.getDisableRollback() == null) return false; if (other.getDisableRollback() != null && other.getDisableRollback().equals(this.getDisableRollback()) == false) return false; if (other.getDriftInformation() == null ^ this.getDriftInformation() == null) return false; if (other.getDriftInformation() != null && other.getDriftInformation().equals(this.getDriftInformation()) == false) return false; if (other.getEnableTerminationProtection() == null ^ this.getEnableTerminationProtection() == null) return false; if (other.getEnableTerminationProtection() != null && other.getEnableTerminationProtection().equals(this.getEnableTerminationProtection()) == false) return false; if (other.getLastUpdatedTime() == null ^ this.getLastUpdatedTime() == null) return false; if (other.getLastUpdatedTime() != null && other.getLastUpdatedTime().equals(this.getLastUpdatedTime()) == false) return false; if (other.getNotificationArns() == null ^ this.getNotificationArns() == null) return false; if (other.getNotificationArns() != null && other.getNotificationArns().equals(this.getNotificationArns()) == false) return false; if (other.getOutputs() == null ^ this.getOutputs() == null) return false; if (other.getOutputs() != null && other.getOutputs().equals(this.getOutputs()) == false) return false; if (other.getRoleArn() == null ^ this.getRoleArn() == null) return false; if (other.getRoleArn() != null && other.getRoleArn().equals(this.getRoleArn()) == false) return false; if (other.getStackId() == null ^ this.getStackId() == null) return false; if (other.getStackId() != null && other.getStackId().equals(this.getStackId()) == false) return false; if (other.getStackName() == null ^ this.getStackName() == null) return false; if (other.getStackName() != null && other.getStackName().equals(this.getStackName()) == false) return false; if (other.getStackStatus() == null ^ this.getStackStatus() == null) return false; if (other.getStackStatus() != null && other.getStackStatus().equals(this.getStackStatus()) == false) return false; if (other.getStackStatusReason() == null ^ this.getStackStatusReason() == null) return false; if (other.getStackStatusReason() != null && other.getStackStatusReason().equals(this.getStackStatusReason()) == false) return false; if (other.getTimeoutInMinutes() == null ^ this.getTimeoutInMinutes() == null) return false; if (other.getTimeoutInMinutes() != null && other.getTimeoutInMinutes().equals(this.getTimeoutInMinutes()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getCapabilities() == null) ? 0 : getCapabilities().hashCode()); hashCode = prime * hashCode + ((getCreationTime() == null) ? 0 : getCreationTime().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getDisableRollback() == null) ? 0 : getDisableRollback().hashCode()); hashCode = prime * hashCode + ((getDriftInformation() == null) ? 0 : getDriftInformation().hashCode()); hashCode = prime * hashCode + ((getEnableTerminationProtection() == null) ? 0 : getEnableTerminationProtection().hashCode()); hashCode = prime * hashCode + ((getLastUpdatedTime() == null) ? 0 : getLastUpdatedTime().hashCode()); hashCode = prime * hashCode + ((getNotificationArns() == null) ? 0 : getNotificationArns().hashCode()); hashCode = prime * hashCode + ((getOutputs() == null) ? 0 : getOutputs().hashCode()); hashCode = prime * hashCode + ((getRoleArn() == null) ? 0 : getRoleArn().hashCode()); hashCode = prime * hashCode + ((getStackId() == null) ? 0 : getStackId().hashCode()); hashCode = prime * hashCode + ((getStackName() == null) ? 0 : getStackName().hashCode()); hashCode = prime * hashCode + ((getStackStatus() == null) ? 0 : getStackStatus().hashCode()); hashCode = prime * hashCode + ((getStackStatusReason() == null) ? 0 : getStackStatusReason().hashCode()); hashCode = prime * hashCode + ((getTimeoutInMinutes() == null) ? 0 : getTimeoutInMinutes().hashCode()); return hashCode; } @Override public AwsCloudFormationStackDetails clone() { try { return (AwsCloudFormationStackDetails) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.securityhub.model.transform.AwsCloudFormationStackDetailsMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy