AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
CreateSnapshotRequest.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/core/utils/memory/stl/AWSVector.h>
9#include <aws/redshift-serverless/RedshiftServerlessRequest.h>
10#include <aws/redshift-serverless/RedshiftServerless_EXPORTS.h>
11#include <aws/redshift-serverless/model/Tag.h>
12
13#include <utility>
14
15namespace Aws {
16namespace RedshiftServerless {
17namespace Model {
18
22 public:
23 AWS_REDSHIFTSERVERLESS_API CreateSnapshotRequest() = default;
24
25 // Service request name is the Operation name which will send this request out,
26 // each operation should has unique request name, so that we can get operation's name from this request.
27 // Note: this is not true for response, multiple operations may have the same response name,
28 // so we can not get operation's name from response.
29 inline virtual const char* GetServiceRequestName() const override { return "CreateSnapshot"; }
30
31 AWS_REDSHIFTSERVERLESS_API Aws::String SerializePayload() const override;
32
33 AWS_REDSHIFTSERVERLESS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
34
36
39 inline const Aws::String& GetNamespaceName() const { return m_namespaceName; }
40 inline bool NamespaceNameHasBeenSet() const { return m_namespaceNameHasBeenSet; }
41 template <typename NamespaceNameT = Aws::String>
42 void SetNamespaceName(NamespaceNameT&& value) {
43 m_namespaceNameHasBeenSet = true;
44 m_namespaceName = std::forward<NamespaceNameT>(value);
45 }
46 template <typename NamespaceNameT = Aws::String>
47 CreateSnapshotRequest& WithNamespaceName(NamespaceNameT&& value) {
48 SetNamespaceName(std::forward<NamespaceNameT>(value));
49 return *this;
50 }
52
54
57 inline int GetRetentionPeriod() const { return m_retentionPeriod; }
58 inline bool RetentionPeriodHasBeenSet() const { return m_retentionPeriodHasBeenSet; }
59 inline void SetRetentionPeriod(int value) {
60 m_retentionPeriodHasBeenSet = true;
61 m_retentionPeriod = value;
62 }
64 SetRetentionPeriod(value);
65 return *this;
66 }
68
70
73 inline const Aws::String& GetSnapshotName() const { return m_snapshotName; }
74 inline bool SnapshotNameHasBeenSet() const { return m_snapshotNameHasBeenSet; }
75 template <typename SnapshotNameT = Aws::String>
76 void SetSnapshotName(SnapshotNameT&& value) {
77 m_snapshotNameHasBeenSet = true;
78 m_snapshotName = std::forward<SnapshotNameT>(value);
79 }
80 template <typename SnapshotNameT = Aws::String>
81 CreateSnapshotRequest& WithSnapshotName(SnapshotNameT&& value) {
82 SetSnapshotName(std::forward<SnapshotNameT>(value));
83 return *this;
84 }
86
88
93 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
94 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
95 template <typename TagsT = Aws::Vector<Tag>>
96 void SetTags(TagsT&& value) {
97 m_tagsHasBeenSet = true;
98 m_tags = std::forward<TagsT>(value);
99 }
100 template <typename TagsT = Aws::Vector<Tag>>
102 SetTags(std::forward<TagsT>(value));
103 return *this;
104 }
105 template <typename TagsT = Tag>
107 m_tagsHasBeenSet = true;
108 m_tags.emplace_back(std::forward<TagsT>(value));
109 return *this;
110 }
112 private:
113 Aws::String m_namespaceName;
114
115 int m_retentionPeriod{0};
116
117 Aws::String m_snapshotName;
118
119 Aws::Vector<Tag> m_tags;
120 bool m_namespaceNameHasBeenSet = false;
121 bool m_retentionPeriodHasBeenSet = false;
122 bool m_snapshotNameHasBeenSet = false;
123 bool m_tagsHasBeenSet = false;
124};
125
126} // namespace Model
127} // namespace RedshiftServerless
128} // namespace Aws
AWS_REDSHIFTSERVERLESS_API CreateSnapshotRequest()=default
CreateSnapshotRequest & WithSnapshotName(SnapshotNameT &&value)
CreateSnapshotRequest & WithNamespaceName(NamespaceNameT &&value)
virtual const char * GetServiceRequestName() const override
AWS_REDSHIFTSERVERLESS_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
AWS_REDSHIFTSERVERLESS_API Aws::String SerializePayload() const override
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector