/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Xml { class XmlNode; } // namespace Xml } // namespace Utils namespace CloudFormation { namespace Model { /** *

The ResourceChange structure describes the resource and the * action that CloudFormation will perform on it if you execute this change * set.

See Also:

AWS * API Reference

*/ class ResourceChange { public: AWS_CLOUDFORMATION_API ResourceChange(); AWS_CLOUDFORMATION_API ResourceChange(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_CLOUDFORMATION_API ResourceChange& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_CLOUDFORMATION_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const; AWS_CLOUDFORMATION_API void OutputToStream(Aws::OStream& oStream, const char* location) const; /** *

The action that CloudFormation takes on the resource, such as * Add (adds a new resource), Modify (changes a * resource), Remove (deletes a resource), Import * (imports a resource), or Dynamic (exact action for the resource * can't be determined).

*/ inline const ChangeAction& GetAction() const{ return m_action; } /** *

The action that CloudFormation takes on the resource, such as * Add (adds a new resource), Modify (changes a * resource), Remove (deletes a resource), Import * (imports a resource), or Dynamic (exact action for the resource * can't be determined).

*/ inline bool ActionHasBeenSet() const { return m_actionHasBeenSet; } /** *

The action that CloudFormation takes on the resource, such as * Add (adds a new resource), Modify (changes a * resource), Remove (deletes a resource), Import * (imports a resource), or Dynamic (exact action for the resource * can't be determined).

*/ inline void SetAction(const ChangeAction& value) { m_actionHasBeenSet = true; m_action = value; } /** *

The action that CloudFormation takes on the resource, such as * Add (adds a new resource), Modify (changes a * resource), Remove (deletes a resource), Import * (imports a resource), or Dynamic (exact action for the resource * can't be determined).

*/ inline void SetAction(ChangeAction&& value) { m_actionHasBeenSet = true; m_action = std::move(value); } /** *

The action that CloudFormation takes on the resource, such as * Add (adds a new resource), Modify (changes a * resource), Remove (deletes a resource), Import * (imports a resource), or Dynamic (exact action for the resource * can't be determined).

*/ inline ResourceChange& WithAction(const ChangeAction& value) { SetAction(value); return *this;} /** *

The action that CloudFormation takes on the resource, such as * Add (adds a new resource), Modify (changes a * resource), Remove (deletes a resource), Import * (imports a resource), or Dynamic (exact action for the resource * can't be determined).

*/ inline ResourceChange& WithAction(ChangeAction&& value) { SetAction(std::move(value)); return *this;} /** *

The resource's logical ID, which is defined in the stack's template.

*/ inline const Aws::String& GetLogicalResourceId() const{ return m_logicalResourceId; } /** *

The resource's logical ID, which is defined in the stack's template.

*/ inline bool LogicalResourceIdHasBeenSet() const { return m_logicalResourceIdHasBeenSet; } /** *

The resource's logical ID, which is defined in the stack's template.

*/ inline void SetLogicalResourceId(const Aws::String& value) { m_logicalResourceIdHasBeenSet = true; m_logicalResourceId = value; } /** *

The resource's logical ID, which is defined in the stack's template.

*/ inline void SetLogicalResourceId(Aws::String&& value) { m_logicalResourceIdHasBeenSet = true; m_logicalResourceId = std::move(value); } /** *

The resource's logical ID, which is defined in the stack's template.

*/ inline void SetLogicalResourceId(const char* value) { m_logicalResourceIdHasBeenSet = true; m_logicalResourceId.assign(value); } /** *

The resource's logical ID, which is defined in the stack's template.

*/ inline ResourceChange& WithLogicalResourceId(const Aws::String& value) { SetLogicalResourceId(value); return *this;} /** *

The resource's logical ID, which is defined in the stack's template.

*/ inline ResourceChange& WithLogicalResourceId(Aws::String&& value) { SetLogicalResourceId(std::move(value)); return *this;} /** *

The resource's logical ID, which is defined in the stack's template.

*/ inline ResourceChange& WithLogicalResourceId(const char* value) { SetLogicalResourceId(value); return *this;} /** *

The resource's physical ID (resource name). Resources that you are adding * don't have physical IDs because they haven't been created.

*/ inline const Aws::String& GetPhysicalResourceId() const{ return m_physicalResourceId; } /** *

The resource's physical ID (resource name). Resources that you are adding * don't have physical IDs because they haven't been created.

*/ inline bool PhysicalResourceIdHasBeenSet() const { return m_physicalResourceIdHasBeenSet; } /** *

The resource's physical ID (resource name). Resources that you are adding * don't have physical IDs because they haven't been created.

*/ inline void SetPhysicalResourceId(const Aws::String& value) { m_physicalResourceIdHasBeenSet = true; m_physicalResourceId = value; } /** *

The resource's physical ID (resource name). Resources that you are adding * don't have physical IDs because they haven't been created.

*/ inline void SetPhysicalResourceId(Aws::String&& value) { m_physicalResourceIdHasBeenSet = true; m_physicalResourceId = std::move(value); } /** *

The resource's physical ID (resource name). Resources that you are adding * don't have physical IDs because they haven't been created.

*/ inline void SetPhysicalResourceId(const char* value) { m_physicalResourceIdHasBeenSet = true; m_physicalResourceId.assign(value); } /** *

The resource's physical ID (resource name). Resources that you are adding * don't have physical IDs because they haven't been created.

*/ inline ResourceChange& WithPhysicalResourceId(const Aws::String& value) { SetPhysicalResourceId(value); return *this;} /** *

The resource's physical ID (resource name). Resources that you are adding * don't have physical IDs because they haven't been created.

*/ inline ResourceChange& WithPhysicalResourceId(Aws::String&& value) { SetPhysicalResourceId(std::move(value)); return *this;} /** *

The resource's physical ID (resource name). Resources that you are adding * don't have physical IDs because they haven't been created.

*/ inline ResourceChange& WithPhysicalResourceId(const char* value) { SetPhysicalResourceId(value); return *this;} /** *

The type of CloudFormation resource, such as * AWS::S3::Bucket.

*/ inline const Aws::String& GetResourceType() const{ return m_resourceType; } /** *

The type of CloudFormation resource, such as * AWS::S3::Bucket.

*/ inline bool ResourceTypeHasBeenSet() const { return m_resourceTypeHasBeenSet; } /** *

The type of CloudFormation resource, such as * AWS::S3::Bucket.

*/ inline void SetResourceType(const Aws::String& value) { m_resourceTypeHasBeenSet = true; m_resourceType = value; } /** *

The type of CloudFormation resource, such as * AWS::S3::Bucket.

*/ inline void SetResourceType(Aws::String&& value) { m_resourceTypeHasBeenSet = true; m_resourceType = std::move(value); } /** *

The type of CloudFormation resource, such as * AWS::S3::Bucket.

*/ inline void SetResourceType(const char* value) { m_resourceTypeHasBeenSet = true; m_resourceType.assign(value); } /** *

The type of CloudFormation resource, such as * AWS::S3::Bucket.

*/ inline ResourceChange& WithResourceType(const Aws::String& value) { SetResourceType(value); return *this;} /** *

The type of CloudFormation resource, such as * AWS::S3::Bucket.

*/ inline ResourceChange& WithResourceType(Aws::String&& value) { SetResourceType(std::move(value)); return *this;} /** *

The type of CloudFormation resource, such as * AWS::S3::Bucket.

*/ inline ResourceChange& WithResourceType(const char* value) { SetResourceType(value); return *this;} /** *

For the Modify action, indicates whether CloudFormation will * replace the resource by creating a new one and deleting the old one. This value * depends on the value of the RequiresRecreation property in the * ResourceTargetDefinition structure. For example, if the * RequiresRecreation field is Always and the * Evaluation field is Static, Replacement * is True. If the RequiresRecreation field is * Always and the Evaluation field is * Dynamic, Replacement is * Conditionally.

If you have multiple changes with different * RequiresRecreation values, the Replacement value * depends on the change with the most impact. A RequiresRecreation * value of Always has the most impact, followed by * Conditionally, and then Never.

*/ inline const Replacement& GetReplacement() const{ return m_replacement; } /** *

For the Modify action, indicates whether CloudFormation will * replace the resource by creating a new one and deleting the old one. This value * depends on the value of the RequiresRecreation property in the * ResourceTargetDefinition structure. For example, if the * RequiresRecreation field is Always and the * Evaluation field is Static, Replacement * is True. If the RequiresRecreation field is * Always and the Evaluation field is * Dynamic, Replacement is * Conditionally.

If you have multiple changes with different * RequiresRecreation values, the Replacement value * depends on the change with the most impact. A RequiresRecreation * value of Always has the most impact, followed by * Conditionally, and then Never.

*/ inline bool ReplacementHasBeenSet() const { return m_replacementHasBeenSet; } /** *

For the Modify action, indicates whether CloudFormation will * replace the resource by creating a new one and deleting the old one. This value * depends on the value of the RequiresRecreation property in the * ResourceTargetDefinition structure. For example, if the * RequiresRecreation field is Always and the * Evaluation field is Static, Replacement * is True. If the RequiresRecreation field is * Always and the Evaluation field is * Dynamic, Replacement is * Conditionally.

If you have multiple changes with different * RequiresRecreation values, the Replacement value * depends on the change with the most impact. A RequiresRecreation * value of Always has the most impact, followed by * Conditionally, and then Never.

*/ inline void SetReplacement(const Replacement& value) { m_replacementHasBeenSet = true; m_replacement = value; } /** *

For the Modify action, indicates whether CloudFormation will * replace the resource by creating a new one and deleting the old one. This value * depends on the value of the RequiresRecreation property in the * ResourceTargetDefinition structure. For example, if the * RequiresRecreation field is Always and the * Evaluation field is Static, Replacement * is True. If the RequiresRecreation field is * Always and the Evaluation field is * Dynamic, Replacement is * Conditionally.

If you have multiple changes with different * RequiresRecreation values, the Replacement value * depends on the change with the most impact. A RequiresRecreation * value of Always has the most impact, followed by * Conditionally, and then Never.

*/ inline void SetReplacement(Replacement&& value) { m_replacementHasBeenSet = true; m_replacement = std::move(value); } /** *

For the Modify action, indicates whether CloudFormation will * replace the resource by creating a new one and deleting the old one. This value * depends on the value of the RequiresRecreation property in the * ResourceTargetDefinition structure. For example, if the * RequiresRecreation field is Always and the * Evaluation field is Static, Replacement * is True. If the RequiresRecreation field is * Always and the Evaluation field is * Dynamic, Replacement is * Conditionally.

If you have multiple changes with different * RequiresRecreation values, the Replacement value * depends on the change with the most impact. A RequiresRecreation * value of Always has the most impact, followed by * Conditionally, and then Never.

*/ inline ResourceChange& WithReplacement(const Replacement& value) { SetReplacement(value); return *this;} /** *

For the Modify action, indicates whether CloudFormation will * replace the resource by creating a new one and deleting the old one. This value * depends on the value of the RequiresRecreation property in the * ResourceTargetDefinition structure. For example, if the * RequiresRecreation field is Always and the * Evaluation field is Static, Replacement * is True. If the RequiresRecreation field is * Always and the Evaluation field is * Dynamic, Replacement is * Conditionally.

If you have multiple changes with different * RequiresRecreation values, the Replacement value * depends on the change with the most impact. A RequiresRecreation * value of Always has the most impact, followed by * Conditionally, and then Never.

*/ inline ResourceChange& WithReplacement(Replacement&& value) { SetReplacement(std::move(value)); return *this;} /** *

For the Modify action, indicates which resource attribute is * triggering this update, such as a change in the resource attribute's * Metadata, Properties, or Tags.

*/ inline const Aws::Vector& GetScope() const{ return m_scope; } /** *

For the Modify action, indicates which resource attribute is * triggering this update, such as a change in the resource attribute's * Metadata, Properties, or Tags.

*/ inline bool ScopeHasBeenSet() const { return m_scopeHasBeenSet; } /** *

For the Modify action, indicates which resource attribute is * triggering this update, such as a change in the resource attribute's * Metadata, Properties, or Tags.

*/ inline void SetScope(const Aws::Vector& value) { m_scopeHasBeenSet = true; m_scope = value; } /** *

For the Modify action, indicates which resource attribute is * triggering this update, such as a change in the resource attribute's * Metadata, Properties, or Tags.

*/ inline void SetScope(Aws::Vector&& value) { m_scopeHasBeenSet = true; m_scope = std::move(value); } /** *

For the Modify action, indicates which resource attribute is * triggering this update, such as a change in the resource attribute's * Metadata, Properties, or Tags.

*/ inline ResourceChange& WithScope(const Aws::Vector& value) { SetScope(value); return *this;} /** *

For the Modify action, indicates which resource attribute is * triggering this update, such as a change in the resource attribute's * Metadata, Properties, or Tags.

*/ inline ResourceChange& WithScope(Aws::Vector&& value) { SetScope(std::move(value)); return *this;} /** *

For the Modify action, indicates which resource attribute is * triggering this update, such as a change in the resource attribute's * Metadata, Properties, or Tags.

*/ inline ResourceChange& AddScope(const ResourceAttribute& value) { m_scopeHasBeenSet = true; m_scope.push_back(value); return *this; } /** *

For the Modify action, indicates which resource attribute is * triggering this update, such as a change in the resource attribute's * Metadata, Properties, or Tags.

*/ inline ResourceChange& AddScope(ResourceAttribute&& value) { m_scopeHasBeenSet = true; m_scope.push_back(std::move(value)); return *this; } /** *

For the Modify action, a list of * ResourceChangeDetail structures that describes the changes that * CloudFormation will make to the resource.

*/ inline const Aws::Vector& GetDetails() const{ return m_details; } /** *

For the Modify action, a list of * ResourceChangeDetail structures that describes the changes that * CloudFormation will make to the resource.

*/ inline bool DetailsHasBeenSet() const { return m_detailsHasBeenSet; } /** *

For the Modify action, a list of * ResourceChangeDetail structures that describes the changes that * CloudFormation will make to the resource.

*/ inline void SetDetails(const Aws::Vector& value) { m_detailsHasBeenSet = true; m_details = value; } /** *

For the Modify action, a list of * ResourceChangeDetail structures that describes the changes that * CloudFormation will make to the resource.

*/ inline void SetDetails(Aws::Vector&& value) { m_detailsHasBeenSet = true; m_details = std::move(value); } /** *

For the Modify action, a list of * ResourceChangeDetail structures that describes the changes that * CloudFormation will make to the resource.

*/ inline ResourceChange& WithDetails(const Aws::Vector& value) { SetDetails(value); return *this;} /** *

For the Modify action, a list of * ResourceChangeDetail structures that describes the changes that * CloudFormation will make to the resource.

*/ inline ResourceChange& WithDetails(Aws::Vector&& value) { SetDetails(std::move(value)); return *this;} /** *

For the Modify action, a list of * ResourceChangeDetail structures that describes the changes that * CloudFormation will make to the resource.

*/ inline ResourceChange& AddDetails(const ResourceChangeDetail& value) { m_detailsHasBeenSet = true; m_details.push_back(value); return *this; } /** *

For the Modify action, a list of * ResourceChangeDetail structures that describes the changes that * CloudFormation will make to the resource.

*/ inline ResourceChange& AddDetails(ResourceChangeDetail&& value) { m_detailsHasBeenSet = true; m_details.push_back(std::move(value)); return *this; } /** *

The change set ID of the nested change set.

*/ inline const Aws::String& GetChangeSetId() const{ return m_changeSetId; } /** *

The change set ID of the nested change set.

*/ inline bool ChangeSetIdHasBeenSet() const { return m_changeSetIdHasBeenSet; } /** *

The change set ID of the nested change set.

*/ inline void SetChangeSetId(const Aws::String& value) { m_changeSetIdHasBeenSet = true; m_changeSetId = value; } /** *

The change set ID of the nested change set.

*/ inline void SetChangeSetId(Aws::String&& value) { m_changeSetIdHasBeenSet = true; m_changeSetId = std::move(value); } /** *

The change set ID of the nested change set.

*/ inline void SetChangeSetId(const char* value) { m_changeSetIdHasBeenSet = true; m_changeSetId.assign(value); } /** *

The change set ID of the nested change set.

*/ inline ResourceChange& WithChangeSetId(const Aws::String& value) { SetChangeSetId(value); return *this;} /** *

The change set ID of the nested change set.

*/ inline ResourceChange& WithChangeSetId(Aws::String&& value) { SetChangeSetId(std::move(value)); return *this;} /** *

The change set ID of the nested change set.

*/ inline ResourceChange& WithChangeSetId(const char* value) { SetChangeSetId(value); return *this;} /** *

Contains information about the module from which the resource was created, if * the resource was created from a module included in the stack template.

*/ inline const ModuleInfo& GetModuleInfo() const{ return m_moduleInfo; } /** *

Contains information about the module from which the resource was created, if * the resource was created from a module included in the stack template.

*/ inline bool ModuleInfoHasBeenSet() const { return m_moduleInfoHasBeenSet; } /** *

Contains information about the module from which the resource was created, if * the resource was created from a module included in the stack template.

*/ inline void SetModuleInfo(const ModuleInfo& value) { m_moduleInfoHasBeenSet = true; m_moduleInfo = value; } /** *

Contains information about the module from which the resource was created, if * the resource was created from a module included in the stack template.

*/ inline void SetModuleInfo(ModuleInfo&& value) { m_moduleInfoHasBeenSet = true; m_moduleInfo = std::move(value); } /** *

Contains information about the module from which the resource was created, if * the resource was created from a module included in the stack template.

*/ inline ResourceChange& WithModuleInfo(const ModuleInfo& value) { SetModuleInfo(value); return *this;} /** *

Contains information about the module from which the resource was created, if * the resource was created from a module included in the stack template.

*/ inline ResourceChange& WithModuleInfo(ModuleInfo&& value) { SetModuleInfo(std::move(value)); return *this;} private: ChangeAction m_action; bool m_actionHasBeenSet = false; Aws::String m_logicalResourceId; bool m_logicalResourceIdHasBeenSet = false; Aws::String m_physicalResourceId; bool m_physicalResourceIdHasBeenSet = false; Aws::String m_resourceType; bool m_resourceTypeHasBeenSet = false; Replacement m_replacement; bool m_replacementHasBeenSet = false; Aws::Vector m_scope; bool m_scopeHasBeenSet = false; Aws::Vector m_details; bool m_detailsHasBeenSet = false; Aws::String m_changeSetId; bool m_changeSetIdHasBeenSet = false; ModuleInfo m_moduleInfo; bool m_moduleInfoHasBeenSet = false; }; } // namespace Model } // namespace CloudFormation } // namespace Aws