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

com.amazonaws.services.cloudformation.model.StackInstanceResourceDriftsSummary Maven / Gradle / Ivy

Go to download

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

There is a newer version: 1.12.778
Show newest version
/*
 * Copyright 2018-2023 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.cloudformation.model;

import java.io.Serializable;
import javax.annotation.Generated;

/**
 * 

* The structure containing summary information about resource drifts for a stack instance. *

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

* The ID of the stack instance. *

*/ private String stackId; /** *

* The logical name of the resource specified in the template. *

*/ private String logicalResourceId; /** *

* The name or unique identifier that corresponds to a physical instance ID of a resource supported by * CloudFormation. *

*/ private String physicalResourceId; /** *

* Context information that enables CloudFormation to uniquely identify a resource. CloudFormation uses context * key-value pairs in cases where a resource's logical and physical IDs aren't enough to uniquely identify that * resource. Each context key-value pair specifies a unique resource that contains the targeted resource. *

*/ private com.amazonaws.internal.SdkInternalList physicalResourceIdContext; /** *

* Type of resource. For more information, go to Amazon * Web Services Resource Types Reference in the CloudFormation User Guide. *

*/ private String resourceType; /** *

* Status of the actual configuration of the resource compared to its expected configuration. These will be present * only for resources whose StackInstanceResourceDriftStatus is MODIFIED. *

*/ private com.amazonaws.internal.SdkInternalList propertyDifferences; /** *

* The drift status of the resource in a stack instance. *

*
    *
  • *

    * DELETED: The resource differs from its expected template configuration in that the resource has been * deleted. *

    *
  • *
  • *

    * MODIFIED: One or more resource properties differ from their expected template values. *

    *
  • *
  • *

    * IN_SYNC: The resource's actual configuration matches its expected template configuration. *

    *
  • *
  • *

    * NOT_CHECKED: CloudFormation doesn't currently return this value. *

    *
  • *
*/ private String stackResourceDriftStatus; /** *

* Time at which the stack instance drift detection operation was initiated. *

*/ private java.util.Date timestamp; /** *

* The ID of the stack instance. *

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

* The ID of the stack instance. *

* * @return The ID of the stack instance. */ public String getStackId() { return this.stackId; } /** *

* The ID of the stack instance. *

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

* The logical name of the resource specified in the template. *

* * @param logicalResourceId * The logical name of the resource specified in the template. */ public void setLogicalResourceId(String logicalResourceId) { this.logicalResourceId = logicalResourceId; } /** *

* The logical name of the resource specified in the template. *

* * @return The logical name of the resource specified in the template. */ public String getLogicalResourceId() { return this.logicalResourceId; } /** *

* The logical name of the resource specified in the template. *

* * @param logicalResourceId * The logical name of the resource specified in the template. * @return Returns a reference to this object so that method calls can be chained together. */ public StackInstanceResourceDriftsSummary withLogicalResourceId(String logicalResourceId) { setLogicalResourceId(logicalResourceId); return this; } /** *

* The name or unique identifier that corresponds to a physical instance ID of a resource supported by * CloudFormation. *

* * @param physicalResourceId * The name or unique identifier that corresponds to a physical instance ID of a resource supported by * CloudFormation. */ public void setPhysicalResourceId(String physicalResourceId) { this.physicalResourceId = physicalResourceId; } /** *

* The name or unique identifier that corresponds to a physical instance ID of a resource supported by * CloudFormation. *

* * @return The name or unique identifier that corresponds to a physical instance ID of a resource supported by * CloudFormation. */ public String getPhysicalResourceId() { return this.physicalResourceId; } /** *

* The name or unique identifier that corresponds to a physical instance ID of a resource supported by * CloudFormation. *

* * @param physicalResourceId * The name or unique identifier that corresponds to a physical instance ID of a resource supported by * CloudFormation. * @return Returns a reference to this object so that method calls can be chained together. */ public StackInstanceResourceDriftsSummary withPhysicalResourceId(String physicalResourceId) { setPhysicalResourceId(physicalResourceId); return this; } /** *

* Context information that enables CloudFormation to uniquely identify a resource. CloudFormation uses context * key-value pairs in cases where a resource's logical and physical IDs aren't enough to uniquely identify that * resource. Each context key-value pair specifies a unique resource that contains the targeted resource. *

* * @return Context information that enables CloudFormation to uniquely identify a resource. CloudFormation uses * context key-value pairs in cases where a resource's logical and physical IDs aren't enough to uniquely * identify that resource. Each context key-value pair specifies a unique resource that contains the * targeted resource. */ public java.util.List getPhysicalResourceIdContext() { if (physicalResourceIdContext == null) { physicalResourceIdContext = new com.amazonaws.internal.SdkInternalList(); } return physicalResourceIdContext; } /** *

* Context information that enables CloudFormation to uniquely identify a resource. CloudFormation uses context * key-value pairs in cases where a resource's logical and physical IDs aren't enough to uniquely identify that * resource. Each context key-value pair specifies a unique resource that contains the targeted resource. *

* * @param physicalResourceIdContext * Context information that enables CloudFormation to uniquely identify a resource. CloudFormation uses * context key-value pairs in cases where a resource's logical and physical IDs aren't enough to uniquely * identify that resource. Each context key-value pair specifies a unique resource that contains the targeted * resource. */ public void setPhysicalResourceIdContext(java.util.Collection physicalResourceIdContext) { if (physicalResourceIdContext == null) { this.physicalResourceIdContext = null; return; } this.physicalResourceIdContext = new com.amazonaws.internal.SdkInternalList(physicalResourceIdContext); } /** *

* Context information that enables CloudFormation to uniquely identify a resource. CloudFormation uses context * key-value pairs in cases where a resource's logical and physical IDs aren't enough to uniquely identify that * resource. Each context key-value pair specifies a unique resource that contains the targeted resource. *

*

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

* * @param physicalResourceIdContext * Context information that enables CloudFormation to uniquely identify a resource. CloudFormation uses * context key-value pairs in cases where a resource's logical and physical IDs aren't enough to uniquely * identify that resource. Each context key-value pair specifies a unique resource that contains the targeted * resource. * @return Returns a reference to this object so that method calls can be chained together. */ public StackInstanceResourceDriftsSummary withPhysicalResourceIdContext(PhysicalResourceIdContextKeyValuePair... physicalResourceIdContext) { if (this.physicalResourceIdContext == null) { setPhysicalResourceIdContext(new com.amazonaws.internal.SdkInternalList(physicalResourceIdContext.length)); } for (PhysicalResourceIdContextKeyValuePair ele : physicalResourceIdContext) { this.physicalResourceIdContext.add(ele); } return this; } /** *

* Context information that enables CloudFormation to uniquely identify a resource. CloudFormation uses context * key-value pairs in cases where a resource's logical and physical IDs aren't enough to uniquely identify that * resource. Each context key-value pair specifies a unique resource that contains the targeted resource. *

* * @param physicalResourceIdContext * Context information that enables CloudFormation to uniquely identify a resource. CloudFormation uses * context key-value pairs in cases where a resource's logical and physical IDs aren't enough to uniquely * identify that resource. Each context key-value pair specifies a unique resource that contains the targeted * resource. * @return Returns a reference to this object so that method calls can be chained together. */ public StackInstanceResourceDriftsSummary withPhysicalResourceIdContext( java.util.Collection physicalResourceIdContext) { setPhysicalResourceIdContext(physicalResourceIdContext); return this; } /** *

* Type of resource. For more information, go to Amazon * Web Services Resource Types Reference in the CloudFormation User Guide. *

* * @param resourceType * Type of resource. For more information, go to Amazon Web Services Resource Types Reference in the CloudFormation User Guide. */ public void setResourceType(String resourceType) { this.resourceType = resourceType; } /** *

* Type of resource. For more information, go to Amazon * Web Services Resource Types Reference in the CloudFormation User Guide. *

* * @return Type of resource. For more information, go to Amazon Web Services Resource Types Reference in the CloudFormation User Guide. */ public String getResourceType() { return this.resourceType; } /** *

* Type of resource. For more information, go to Amazon * Web Services Resource Types Reference in the CloudFormation User Guide. *

* * @param resourceType * Type of resource. For more information, go to Amazon Web Services Resource Types Reference in the CloudFormation User Guide. * @return Returns a reference to this object so that method calls can be chained together. */ public StackInstanceResourceDriftsSummary withResourceType(String resourceType) { setResourceType(resourceType); return this; } /** *

* Status of the actual configuration of the resource compared to its expected configuration. These will be present * only for resources whose StackInstanceResourceDriftStatus is MODIFIED. *

* * @return Status of the actual configuration of the resource compared to its expected configuration. These will be * present only for resources whose StackInstanceResourceDriftStatus is MODIFIED. */ public java.util.List getPropertyDifferences() { if (propertyDifferences == null) { propertyDifferences = new com.amazonaws.internal.SdkInternalList(); } return propertyDifferences; } /** *

* Status of the actual configuration of the resource compared to its expected configuration. These will be present * only for resources whose StackInstanceResourceDriftStatus is MODIFIED. *

* * @param propertyDifferences * Status of the actual configuration of the resource compared to its expected configuration. These will be * present only for resources whose StackInstanceResourceDriftStatus is MODIFIED. */ public void setPropertyDifferences(java.util.Collection propertyDifferences) { if (propertyDifferences == null) { this.propertyDifferences = null; return; } this.propertyDifferences = new com.amazonaws.internal.SdkInternalList(propertyDifferences); } /** *

* Status of the actual configuration of the resource compared to its expected configuration. These will be present * only for resources whose StackInstanceResourceDriftStatus is MODIFIED. *

*

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

* * @param propertyDifferences * Status of the actual configuration of the resource compared to its expected configuration. These will be * present only for resources whose StackInstanceResourceDriftStatus is MODIFIED. * @return Returns a reference to this object so that method calls can be chained together. */ public StackInstanceResourceDriftsSummary withPropertyDifferences(PropertyDifference... propertyDifferences) { if (this.propertyDifferences == null) { setPropertyDifferences(new com.amazonaws.internal.SdkInternalList(propertyDifferences.length)); } for (PropertyDifference ele : propertyDifferences) { this.propertyDifferences.add(ele); } return this; } /** *

* Status of the actual configuration of the resource compared to its expected configuration. These will be present * only for resources whose StackInstanceResourceDriftStatus is MODIFIED. *

* * @param propertyDifferences * Status of the actual configuration of the resource compared to its expected configuration. These will be * present only for resources whose StackInstanceResourceDriftStatus is MODIFIED. * @return Returns a reference to this object so that method calls can be chained together. */ public StackInstanceResourceDriftsSummary withPropertyDifferences(java.util.Collection propertyDifferences) { setPropertyDifferences(propertyDifferences); return this; } /** *

* The drift status of the resource in a stack instance. *

*
    *
  • *

    * DELETED: The resource differs from its expected template configuration in that the resource has been * deleted. *

    *
  • *
  • *

    * MODIFIED: One or more resource properties differ from their expected template values. *

    *
  • *
  • *

    * IN_SYNC: The resource's actual configuration matches its expected template configuration. *

    *
  • *
  • *

    * NOT_CHECKED: CloudFormation doesn't currently return this value. *

    *
  • *
* * @param stackResourceDriftStatus * The drift status of the resource in a stack instance.

*
    *
  • *

    * DELETED: The resource differs from its expected template configuration in that the resource * has been deleted. *

    *
  • *
  • *

    * MODIFIED: One or more resource properties differ from their expected template values. *

    *
  • *
  • *

    * IN_SYNC: The resource's actual configuration matches its expected template configuration. *

    *
  • *
  • *

    * NOT_CHECKED: CloudFormation doesn't currently return this value. *

    *
  • * @see StackResourceDriftStatus */ public void setStackResourceDriftStatus(String stackResourceDriftStatus) { this.stackResourceDriftStatus = stackResourceDriftStatus; } /** *

    * The drift status of the resource in a stack instance. *

    *
      *
    • *

      * DELETED: The resource differs from its expected template configuration in that the resource has been * deleted. *

      *
    • *
    • *

      * MODIFIED: One or more resource properties differ from their expected template values. *

      *
    • *
    • *

      * IN_SYNC: The resource's actual configuration matches its expected template configuration. *

      *
    • *
    • *

      * NOT_CHECKED: CloudFormation doesn't currently return this value. *

      *
    • *
    * * @return The drift status of the resource in a stack instance.

    *
      *
    • *

      * DELETED: The resource differs from its expected template configuration in that the resource * has been deleted. *

      *
    • *
    • *

      * MODIFIED: One or more resource properties differ from their expected template values. *

      *
    • *
    • *

      * IN_SYNC: The resource's actual configuration matches its expected template configuration. *

      *
    • *
    • *

      * NOT_CHECKED: CloudFormation doesn't currently return this value. *

      *
    • * @see StackResourceDriftStatus */ public String getStackResourceDriftStatus() { return this.stackResourceDriftStatus; } /** *

      * The drift status of the resource in a stack instance. *

      *
        *
      • *

        * DELETED: The resource differs from its expected template configuration in that the resource has been * deleted. *

        *
      • *
      • *

        * MODIFIED: One or more resource properties differ from their expected template values. *

        *
      • *
      • *

        * IN_SYNC: The resource's actual configuration matches its expected template configuration. *

        *
      • *
      • *

        * NOT_CHECKED: CloudFormation doesn't currently return this value. *

        *
      • *
      * * @param stackResourceDriftStatus * The drift status of the resource in a stack instance.

      *
        *
      • *

        * DELETED: The resource differs from its expected template configuration in that the resource * has been deleted. *

        *
      • *
      • *

        * MODIFIED: One or more resource properties differ from their expected template values. *

        *
      • *
      • *

        * IN_SYNC: The resource's actual configuration matches its expected template configuration. *

        *
      • *
      • *

        * NOT_CHECKED: CloudFormation doesn't currently return this value. *

        *
      • * @return Returns a reference to this object so that method calls can be chained together. * @see StackResourceDriftStatus */ public StackInstanceResourceDriftsSummary withStackResourceDriftStatus(String stackResourceDriftStatus) { setStackResourceDriftStatus(stackResourceDriftStatus); return this; } /** *

        * The drift status of the resource in a stack instance. *

        *
          *
        • *

          * DELETED: The resource differs from its expected template configuration in that the resource has been * deleted. *

          *
        • *
        • *

          * MODIFIED: One or more resource properties differ from their expected template values. *

          *
        • *
        • *

          * IN_SYNC: The resource's actual configuration matches its expected template configuration. *

          *
        • *
        • *

          * NOT_CHECKED: CloudFormation doesn't currently return this value. *

          *
        • *
        * * @param stackResourceDriftStatus * The drift status of the resource in a stack instance.

        *
          *
        • *

          * DELETED: The resource differs from its expected template configuration in that the resource * has been deleted. *

          *
        • *
        • *

          * MODIFIED: One or more resource properties differ from their expected template values. *

          *
        • *
        • *

          * IN_SYNC: The resource's actual configuration matches its expected template configuration. *

          *
        • *
        • *

          * NOT_CHECKED: CloudFormation doesn't currently return this value. *

          *
        • * @return Returns a reference to this object so that method calls can be chained together. * @see StackResourceDriftStatus */ public StackInstanceResourceDriftsSummary withStackResourceDriftStatus(StackResourceDriftStatus stackResourceDriftStatus) { this.stackResourceDriftStatus = stackResourceDriftStatus.toString(); return this; } /** *

          * Time at which the stack instance drift detection operation was initiated. *

          * * @param timestamp * Time at which the stack instance drift detection operation was initiated. */ public void setTimestamp(java.util.Date timestamp) { this.timestamp = timestamp; } /** *

          * Time at which the stack instance drift detection operation was initiated. *

          * * @return Time at which the stack instance drift detection operation was initiated. */ public java.util.Date getTimestamp() { return this.timestamp; } /** *

          * Time at which the stack instance drift detection operation was initiated. *

          * * @param timestamp * Time at which the stack instance drift detection operation was initiated. * @return Returns a reference to this object so that method calls can be chained together. */ public StackInstanceResourceDriftsSummary withTimestamp(java.util.Date timestamp) { setTimestamp(timestamp); 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 (getStackId() != null) sb.append("StackId: ").append(getStackId()).append(","); if (getLogicalResourceId() != null) sb.append("LogicalResourceId: ").append(getLogicalResourceId()).append(","); if (getPhysicalResourceId() != null) sb.append("PhysicalResourceId: ").append(getPhysicalResourceId()).append(","); if (getPhysicalResourceIdContext() != null) sb.append("PhysicalResourceIdContext: ").append(getPhysicalResourceIdContext()).append(","); if (getResourceType() != null) sb.append("ResourceType: ").append(getResourceType()).append(","); if (getPropertyDifferences() != null) sb.append("PropertyDifferences: ").append(getPropertyDifferences()).append(","); if (getStackResourceDriftStatus() != null) sb.append("StackResourceDriftStatus: ").append(getStackResourceDriftStatus()).append(","); if (getTimestamp() != null) sb.append("Timestamp: ").append(getTimestamp()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof StackInstanceResourceDriftsSummary == false) return false; StackInstanceResourceDriftsSummary other = (StackInstanceResourceDriftsSummary) obj; if (other.getStackId() == null ^ this.getStackId() == null) return false; if (other.getStackId() != null && other.getStackId().equals(this.getStackId()) == false) return false; if (other.getLogicalResourceId() == null ^ this.getLogicalResourceId() == null) return false; if (other.getLogicalResourceId() != null && other.getLogicalResourceId().equals(this.getLogicalResourceId()) == false) return false; if (other.getPhysicalResourceId() == null ^ this.getPhysicalResourceId() == null) return false; if (other.getPhysicalResourceId() != null && other.getPhysicalResourceId().equals(this.getPhysicalResourceId()) == false) return false; if (other.getPhysicalResourceIdContext() == null ^ this.getPhysicalResourceIdContext() == null) return false; if (other.getPhysicalResourceIdContext() != null && other.getPhysicalResourceIdContext().equals(this.getPhysicalResourceIdContext()) == false) return false; if (other.getResourceType() == null ^ this.getResourceType() == null) return false; if (other.getResourceType() != null && other.getResourceType().equals(this.getResourceType()) == false) return false; if (other.getPropertyDifferences() == null ^ this.getPropertyDifferences() == null) return false; if (other.getPropertyDifferences() != null && other.getPropertyDifferences().equals(this.getPropertyDifferences()) == false) return false; if (other.getStackResourceDriftStatus() == null ^ this.getStackResourceDriftStatus() == null) return false; if (other.getStackResourceDriftStatus() != null && other.getStackResourceDriftStatus().equals(this.getStackResourceDriftStatus()) == false) return false; if (other.getTimestamp() == null ^ this.getTimestamp() == null) return false; if (other.getTimestamp() != null && other.getTimestamp().equals(this.getTimestamp()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getStackId() == null) ? 0 : getStackId().hashCode()); hashCode = prime * hashCode + ((getLogicalResourceId() == null) ? 0 : getLogicalResourceId().hashCode()); hashCode = prime * hashCode + ((getPhysicalResourceId() == null) ? 0 : getPhysicalResourceId().hashCode()); hashCode = prime * hashCode + ((getPhysicalResourceIdContext() == null) ? 0 : getPhysicalResourceIdContext().hashCode()); hashCode = prime * hashCode + ((getResourceType() == null) ? 0 : getResourceType().hashCode()); hashCode = prime * hashCode + ((getPropertyDifferences() == null) ? 0 : getPropertyDifferences().hashCode()); hashCode = prime * hashCode + ((getStackResourceDriftStatus() == null) ? 0 : getStackResourceDriftStatus().hashCode()); hashCode = prime * hashCode + ((getTimestamp() == null) ? 0 : getTimestamp().hashCode()); return hashCode; } @Override public StackInstanceResourceDriftsSummary clone() { try { return (StackInstanceResourceDriftsSummary) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy