/** * 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 Redshift { namespace Model { /** *

The result of the CreateSnapshotCopyGrant action.

See * Also:

AWS * API Reference

*/ class CreateSnapshotCopyGrantRequest : public RedshiftRequest { public: AWS_REDSHIFT_API CreateSnapshotCopyGrantRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "CreateSnapshotCopyGrant"; } AWS_REDSHIFT_API Aws::String SerializePayload() const override; protected: AWS_REDSHIFT_API void DumpBodyToUrl(Aws::Http::URI& uri ) const override; public: /** *

The name of the snapshot copy grant. This name must be unique in the region * for the Amazon Web Services account.

Constraints:

  • Must * contain from 1 to 63 alphanumeric characters or hyphens.

  • *

    Alphabetic characters must be lowercase.

  • First character * must be a letter.

  • Cannot end with a hyphen or contain two * consecutive hyphens.

  • Must be unique for all clusters within an * Amazon Web Services account.

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

The name of the snapshot copy grant. This name must be unique in the region * for the Amazon Web Services account.

Constraints:

  • Must * contain from 1 to 63 alphanumeric characters or hyphens.

  • *

    Alphabetic characters must be lowercase.

  • First character * must be a letter.

  • Cannot end with a hyphen or contain two * consecutive hyphens.

  • Must be unique for all clusters within an * Amazon Web Services account.

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

The name of the snapshot copy grant. This name must be unique in the region * for the Amazon Web Services account.

Constraints:

  • Must * contain from 1 to 63 alphanumeric characters or hyphens.

  • *

    Alphabetic characters must be lowercase.

  • First character * must be a letter.

  • Cannot end with a hyphen or contain two * consecutive hyphens.

  • Must be unique for all clusters within an * Amazon Web Services account.

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

The name of the snapshot copy grant. This name must be unique in the region * for the Amazon Web Services account.

Constraints:

  • Must * contain from 1 to 63 alphanumeric characters or hyphens.

  • *

    Alphabetic characters must be lowercase.

  • First character * must be a letter.

  • Cannot end with a hyphen or contain two * consecutive hyphens.

  • Must be unique for all clusters within an * Amazon Web Services account.

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

The name of the snapshot copy grant. This name must be unique in the region * for the Amazon Web Services account.

Constraints:

  • Must * contain from 1 to 63 alphanumeric characters or hyphens.

  • *

    Alphabetic characters must be lowercase.

  • First character * must be a letter.

  • Cannot end with a hyphen or contain two * consecutive hyphens.

  • Must be unique for all clusters within an * Amazon Web Services account.

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

The name of the snapshot copy grant. This name must be unique in the region * for the Amazon Web Services account.

Constraints:

  • Must * contain from 1 to 63 alphanumeric characters or hyphens.

  • *

    Alphabetic characters must be lowercase.

  • First character * must be a letter.

  • Cannot end with a hyphen or contain two * consecutive hyphens.

  • Must be unique for all clusters within an * Amazon Web Services account.

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

The name of the snapshot copy grant. This name must be unique in the region * for the Amazon Web Services account.

Constraints:

  • Must * contain from 1 to 63 alphanumeric characters or hyphens.

  • *

    Alphabetic characters must be lowercase.

  • First character * must be a letter.

  • Cannot end with a hyphen or contain two * consecutive hyphens.

  • Must be unique for all clusters within an * Amazon Web Services account.

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

The name of the snapshot copy grant. This name must be unique in the region * for the Amazon Web Services account.

Constraints:

  • Must * contain from 1 to 63 alphanumeric characters or hyphens.

  • *

    Alphabetic characters must be lowercase.

  • First character * must be a letter.

  • Cannot end with a hyphen or contain two * consecutive hyphens.

  • Must be unique for all clusters within an * Amazon Web Services account.

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

The unique identifier of the encrypted symmetric key to which to grant Amazon * Redshift permission. If no key is specified, the default key is used.

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

The unique identifier of the encrypted symmetric key to which to grant Amazon * Redshift permission. If no key is specified, the default key is used.

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

The unique identifier of the encrypted symmetric key to which to grant Amazon * Redshift permission. If no key is specified, the default key is used.

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

The unique identifier of the encrypted symmetric key to which to grant Amazon * Redshift permission. If no key is specified, the default key is used.

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

The unique identifier of the encrypted symmetric key to which to grant Amazon * Redshift permission. If no key is specified, the default key is used.

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

The unique identifier of the encrypted symmetric key to which to grant Amazon * Redshift permission. If no key is specified, the default key is used.

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

The unique identifier of the encrypted symmetric key to which to grant Amazon * Redshift permission. If no key is specified, the default key is used.

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

The unique identifier of the encrypted symmetric key to which to grant Amazon * Redshift permission. If no key is specified, the default key is used.

*/ inline CreateSnapshotCopyGrantRequest& 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 CreateSnapshotCopyGrantRequest& WithTags(const Aws::Vector& value) { SetTags(value); return *this;} /** *

A list of tag instances.

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

A list of tag instances.

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

A list of tag instances.

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