/** * 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 RedshiftServerless { namespace Model { /** */ class CreateSnapshotRequest : public RedshiftServerlessRequest { public: AWS_REDSHIFTSERVERLESS_API CreateSnapshotRequest(); // 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 "CreateSnapshot"; } AWS_REDSHIFTSERVERLESS_API Aws::String SerializePayload() const override; AWS_REDSHIFTSERVERLESS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

The namespace to create a snapshot for.

*/ inline const Aws::String& GetNamespaceName() const{ return m_namespaceName; } /** *

The namespace to create a snapshot for.

*/ inline bool NamespaceNameHasBeenSet() const { return m_namespaceNameHasBeenSet; } /** *

The namespace to create a snapshot for.

*/ inline void SetNamespaceName(const Aws::String& value) { m_namespaceNameHasBeenSet = true; m_namespaceName = value; } /** *

The namespace to create a snapshot for.

*/ inline void SetNamespaceName(Aws::String&& value) { m_namespaceNameHasBeenSet = true; m_namespaceName = std::move(value); } /** *

The namespace to create a snapshot for.

*/ inline void SetNamespaceName(const char* value) { m_namespaceNameHasBeenSet = true; m_namespaceName.assign(value); } /** *

The namespace to create a snapshot for.

*/ inline CreateSnapshotRequest& WithNamespaceName(const Aws::String& value) { SetNamespaceName(value); return *this;} /** *

The namespace to create a snapshot for.

*/ inline CreateSnapshotRequest& WithNamespaceName(Aws::String&& value) { SetNamespaceName(std::move(value)); return *this;} /** *

The namespace to create a snapshot for.

*/ inline CreateSnapshotRequest& WithNamespaceName(const char* value) { SetNamespaceName(value); return *this;} /** *

How long to retain the created snapshot.

*/ inline int GetRetentionPeriod() const{ return m_retentionPeriod; } /** *

How long to retain the created snapshot.

*/ inline bool RetentionPeriodHasBeenSet() const { return m_retentionPeriodHasBeenSet; } /** *

How long to retain the created snapshot.

*/ inline void SetRetentionPeriod(int value) { m_retentionPeriodHasBeenSet = true; m_retentionPeriod = value; } /** *

How long to retain the created snapshot.

*/ inline CreateSnapshotRequest& WithRetentionPeriod(int value) { SetRetentionPeriod(value); return *this;} /** *

The name of the snapshot.

*/ inline const Aws::String& GetSnapshotName() const{ return m_snapshotName; } /** *

The name of the snapshot.

*/ inline bool SnapshotNameHasBeenSet() const { return m_snapshotNameHasBeenSet; } /** *

The name of the snapshot.

*/ inline void SetSnapshotName(const Aws::String& value) { m_snapshotNameHasBeenSet = true; m_snapshotName = value; } /** *

The name of the snapshot.

*/ inline void SetSnapshotName(Aws::String&& value) { m_snapshotNameHasBeenSet = true; m_snapshotName = std::move(value); } /** *

The name of the snapshot.

*/ inline void SetSnapshotName(const char* value) { m_snapshotNameHasBeenSet = true; m_snapshotName.assign(value); } /** *

The name of the snapshot.

*/ inline CreateSnapshotRequest& WithSnapshotName(const Aws::String& value) { SetSnapshotName(value); return *this;} /** *

The name of the snapshot.

*/ inline CreateSnapshotRequest& WithSnapshotName(Aws::String&& value) { SetSnapshotName(std::move(value)); return *this;} /** *

The name of the snapshot.

*/ inline CreateSnapshotRequest& WithSnapshotName(const char* value) { SetSnapshotName(value); return *this;} /** *

An array of Tag * objects to associate with the snapshot.

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

An array of Tag * objects to associate with the snapshot.

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

An array of Tag * objects to associate with the snapshot.

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

An array of Tag * objects to associate with the snapshot.

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

An array of Tag * objects to associate with the snapshot.

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

An array of Tag * objects to associate with the snapshot.

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

An array of Tag * objects to associate with the snapshot.

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

An array of Tag * objects to associate with the snapshot.

*/ inline CreateSnapshotRequest& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; } private: Aws::String m_namespaceName; bool m_namespaceNameHasBeenSet = false; int m_retentionPeriod; bool m_retentionPeriodHasBeenSet = false; Aws::String m_snapshotName; bool m_snapshotNameHasBeenSet = false; Aws::Vector m_tags; bool m_tagsHasBeenSet = false; }; } // namespace Model } // namespace RedshiftServerless } // namespace Aws