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

The snapshot copy grant that grants Amazon Redshift permission to encrypt * copied snapshots with the specified customer master key (CMK) from AWS KMS in * the destination region.

For more information about managing snapshot * copy grants, go to Amazon * Redshift Database Encryption in the Amazon Redshift Cluster Management * Guide.

See Also:

AWS * API Reference

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

The name of the snapshot copy grant.

*/ inline const Aws::String& GetSnapshotCopyGrantName() const{ return m_snapshotCopyGrantName; } /** *

The name of the snapshot copy grant.

*/ inline bool SnapshotCopyGrantNameHasBeenSet() const { return m_snapshotCopyGrantNameHasBeenSet; } /** *

The name of the snapshot copy grant.

*/ inline void SetSnapshotCopyGrantName(const Aws::String& value) { m_snapshotCopyGrantNameHasBeenSet = true; m_snapshotCopyGrantName = value; } /** *

The name of the snapshot copy grant.

*/ inline void SetSnapshotCopyGrantName(Aws::String&& value) { m_snapshotCopyGrantNameHasBeenSet = true; m_snapshotCopyGrantName = std::move(value); } /** *

The name of the snapshot copy grant.

*/ inline void SetSnapshotCopyGrantName(const char* value) { m_snapshotCopyGrantNameHasBeenSet = true; m_snapshotCopyGrantName.assign(value); } /** *

The name of the snapshot copy grant.

*/ inline SnapshotCopyGrant& WithSnapshotCopyGrantName(const Aws::String& value) { SetSnapshotCopyGrantName(value); return *this;} /** *

The name of the snapshot copy grant.

*/ inline SnapshotCopyGrant& WithSnapshotCopyGrantName(Aws::String&& value) { SetSnapshotCopyGrantName(std::move(value)); return *this;} /** *

The name of the snapshot copy grant.

*/ inline SnapshotCopyGrant& WithSnapshotCopyGrantName(const char* value) { SetSnapshotCopyGrantName(value); return *this;} /** *

The unique identifier of the customer master key (CMK) in AWS KMS to which * Amazon Redshift is granted permission.

*/ inline const Aws::String& GetKmsKeyId() const{ return m_kmsKeyId; } /** *

The unique identifier of the customer master key (CMK) in AWS KMS to which * Amazon Redshift is granted permission.

*/ inline bool KmsKeyIdHasBeenSet() const { return m_kmsKeyIdHasBeenSet; } /** *

The unique identifier of the customer master key (CMK) in AWS KMS to which * Amazon Redshift is granted permission.

*/ inline void SetKmsKeyId(const Aws::String& value) { m_kmsKeyIdHasBeenSet = true; m_kmsKeyId = value; } /** *

The unique identifier of the customer master key (CMK) in AWS KMS to which * Amazon Redshift is granted permission.

*/ inline void SetKmsKeyId(Aws::String&& value) { m_kmsKeyIdHasBeenSet = true; m_kmsKeyId = std::move(value); } /** *

The unique identifier of the customer master key (CMK) in AWS KMS to which * Amazon Redshift is granted permission.

*/ inline void SetKmsKeyId(const char* value) { m_kmsKeyIdHasBeenSet = true; m_kmsKeyId.assign(value); } /** *

The unique identifier of the customer master key (CMK) in AWS KMS to which * Amazon Redshift is granted permission.

*/ inline SnapshotCopyGrant& WithKmsKeyId(const Aws::String& value) { SetKmsKeyId(value); return *this;} /** *

The unique identifier of the customer master key (CMK) in AWS KMS to which * Amazon Redshift is granted permission.

*/ inline SnapshotCopyGrant& WithKmsKeyId(Aws::String&& value) { SetKmsKeyId(std::move(value)); return *this;} /** *

The unique identifier of the customer master key (CMK) in AWS KMS to which * Amazon Redshift is granted permission.

*/ inline SnapshotCopyGrant& WithKmsKeyId(const char* value) { SetKmsKeyId(value); return *this;} /** *

A list of tag instances.

*/ inline const Aws::Vector& GetTags() const{ return m_tags; } /** *

A list of tag instances.

*/ inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; } /** *

A list of tag instances.

*/ inline void SetTags(const Aws::Vector& value) { m_tagsHasBeenSet = true; m_tags = value; } /** *

A list of tag instances.

*/ inline void SetTags(Aws::Vector&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); } /** *

A list of tag instances.

*/ inline SnapshotCopyGrant& WithTags(const Aws::Vector& value) { SetTags(value); return *this;} /** *

A list of tag instances.

*/ inline SnapshotCopyGrant& WithTags(Aws::Vector&& value) { SetTags(std::move(value)); return *this;} /** *

A list of tag instances.

*/ inline SnapshotCopyGrant& AddTags(const Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; } /** *

A list of tag instances.

*/ inline SnapshotCopyGrant& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; } private: Aws::String m_snapshotCopyGrantName; bool m_snapshotCopyGrantNameHasBeenSet; Aws::String m_kmsKeyId; bool m_kmsKeyIdHasBeenSet; Aws::Vector m_tags; bool m_tagsHasBeenSet; }; } // namespace Model } // namespace Redshift } // namespace Aws