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/elasticache/ElastiCacheRequest.h>
10#include <aws/elasticache/ElastiCache_EXPORTS.h>
11#include <aws/elasticache/model/Tag.h>
12
13#include <utility>
14
15namespace Aws {
16namespace ElastiCache {
17namespace Model {
18
26 public:
27 AWS_ELASTICACHE_API CreateSnapshotRequest() = default;
28
29 // Service request name is the Operation name which will send this request out,
30 // each operation should has unique request name, so that we can get operation's name from this request.
31 // Note: this is not true for response, multiple operations may have the same response name,
32 // so we can not get operation's name from response.
33 inline virtual const char* GetServiceRequestName() const override { return "CreateSnapshot"; }
34
35 AWS_ELASTICACHE_API Aws::String SerializePayload() const override;
36
37 protected:
38 AWS_ELASTICACHE_API void DumpBodyToUrl(Aws::Http::URI& uri) const override;
39
40 public:
42
46 inline const Aws::String& GetReplicationGroupId() const { return m_replicationGroupId; }
47 inline bool ReplicationGroupIdHasBeenSet() const { return m_replicationGroupIdHasBeenSet; }
48 template <typename ReplicationGroupIdT = Aws::String>
49 void SetReplicationGroupId(ReplicationGroupIdT&& value) {
50 m_replicationGroupIdHasBeenSet = true;
51 m_replicationGroupId = std::forward<ReplicationGroupIdT>(value);
52 }
53 template <typename ReplicationGroupIdT = Aws::String>
54 CreateSnapshotRequest& WithReplicationGroupId(ReplicationGroupIdT&& value) {
55 SetReplicationGroupId(std::forward<ReplicationGroupIdT>(value));
56 return *this;
57 }
59
61
65 inline const Aws::String& GetCacheClusterId() const { return m_cacheClusterId; }
66 inline bool CacheClusterIdHasBeenSet() const { return m_cacheClusterIdHasBeenSet; }
67 template <typename CacheClusterIdT = Aws::String>
68 void SetCacheClusterId(CacheClusterIdT&& value) {
69 m_cacheClusterIdHasBeenSet = true;
70 m_cacheClusterId = std::forward<CacheClusterIdT>(value);
71 }
72 template <typename CacheClusterIdT = Aws::String>
73 CreateSnapshotRequest& WithCacheClusterId(CacheClusterIdT&& value) {
74 SetCacheClusterId(std::forward<CacheClusterIdT>(value));
75 return *this;
76 }
78
80
83 inline const Aws::String& GetSnapshotName() const { return m_snapshotName; }
84 inline bool SnapshotNameHasBeenSet() const { return m_snapshotNameHasBeenSet; }
85 template <typename SnapshotNameT = Aws::String>
86 void SetSnapshotName(SnapshotNameT&& value) {
87 m_snapshotNameHasBeenSet = true;
88 m_snapshotName = std::forward<SnapshotNameT>(value);
89 }
90 template <typename SnapshotNameT = Aws::String>
91 CreateSnapshotRequest& WithSnapshotName(SnapshotNameT&& value) {
92 SetSnapshotName(std::forward<SnapshotNameT>(value));
93 return *this;
94 }
96
98
101 inline const Aws::String& GetKmsKeyId() const { return m_kmsKeyId; }
102 inline bool KmsKeyIdHasBeenSet() const { return m_kmsKeyIdHasBeenSet; }
103 template <typename KmsKeyIdT = Aws::String>
104 void SetKmsKeyId(KmsKeyIdT&& value) {
105 m_kmsKeyIdHasBeenSet = true;
106 m_kmsKeyId = std::forward<KmsKeyIdT>(value);
107 }
108 template <typename KmsKeyIdT = Aws::String>
110 SetKmsKeyId(std::forward<KmsKeyIdT>(value));
111 return *this;
112 }
114
116
120 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
121 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
122 template <typename TagsT = Aws::Vector<Tag>>
123 void SetTags(TagsT&& value) {
124 m_tagsHasBeenSet = true;
125 m_tags = std::forward<TagsT>(value);
126 }
127 template <typename TagsT = Aws::Vector<Tag>>
129 SetTags(std::forward<TagsT>(value));
130 return *this;
131 }
132 template <typename TagsT = Tag>
134 m_tagsHasBeenSet = true;
135 m_tags.emplace_back(std::forward<TagsT>(value));
136 return *this;
137 }
139 private:
140 Aws::String m_replicationGroupId;
141
142 Aws::String m_cacheClusterId;
143
144 Aws::String m_snapshotName;
145
146 Aws::String m_kmsKeyId;
147
148 Aws::Vector<Tag> m_tags;
149 bool m_replicationGroupIdHasBeenSet = false;
150 bool m_cacheClusterIdHasBeenSet = false;
151 bool m_snapshotNameHasBeenSet = false;
152 bool m_kmsKeyIdHasBeenSet = false;
153 bool m_tagsHasBeenSet = false;
154};
155
156} // namespace Model
157} // namespace ElastiCache
158} // namespace Aws
CreateSnapshotRequest & WithTags(TagsT &&value)
AWS_ELASTICACHE_API CreateSnapshotRequest()=default
CreateSnapshotRequest & WithSnapshotName(SnapshotNameT &&value)
CreateSnapshotRequest & WithReplicationGroupId(ReplicationGroupIdT &&value)
virtual const char * GetServiceRequestName() const override
CreateSnapshotRequest & WithCacheClusterId(CacheClusterIdT &&value)
CreateSnapshotRequest & WithKmsKeyId(KmsKeyIdT &&value)
CreateSnapshotRequest & AddTags(TagsT &&value)
void SetReplicationGroupId(ReplicationGroupIdT &&value)
AWS_ELASTICACHE_API Aws::String SerializePayload() const override
AWS_ELASTICACHE_API void DumpBodyToUrl(Aws::Http::URI &uri) const override
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector