AWS SDK for C++

AWS SDK for C++ Version 1.11.937

Loading...
Searching...
No Matches
Backup.h
1
6#pragma once
7#include <aws/cloudhsmv2/CloudHSMV2_EXPORTS.h>
8#include <aws/cloudhsmv2/model/BackupState.h>
9#include <aws/cloudhsmv2/model/ClusterMode.h>
10#include <aws/cloudhsmv2/model/Tag.h>
11#include <aws/core/utils/DateTime.h>
12#include <aws/core/utils/memory/stl/AWSString.h>
13#include <aws/core/utils/memory/stl/AWSVector.h>
14#include <aws/crt/cbor/Cbor.h>
15
16#include <utility>
17
18namespace Aws {
19namespace Utils {
20namespace Cbor {
21class CborValue;
22} // namespace Cbor
23} // namespace Utils
24namespace CloudHSMV2 {
25namespace Model {
26
39class Backup {
40 public:
41 AWS_CLOUDHSMV2_API Backup() = default;
42 AWS_CLOUDHSMV2_API Backup(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
43 AWS_CLOUDHSMV2_API Backup& operator=(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
44 AWS_CLOUDHSMV2_API void CborEncode(Aws::Crt::Cbor::CborEncoder& encoder) const;
45
47
50 inline const Aws::String& GetBackupId() const { return m_backupId; }
51 inline bool BackupIdHasBeenSet() const { return m_backupIdHasBeenSet; }
52 template <typename BackupIdT = Aws::String>
53 void SetBackupId(BackupIdT&& value) {
54 m_backupIdHasBeenSet = true;
55 m_backupId = std::forward<BackupIdT>(value);
56 }
57 template <typename BackupIdT = Aws::String>
58 Backup& WithBackupId(BackupIdT&& value) {
59 SetBackupId(std::forward<BackupIdT>(value));
60 return *this;
61 }
63
65
68 inline const Aws::String& GetBackupArn() const { return m_backupArn; }
69 inline bool BackupArnHasBeenSet() const { return m_backupArnHasBeenSet; }
70 template <typename BackupArnT = Aws::String>
71 void SetBackupArn(BackupArnT&& value) {
72 m_backupArnHasBeenSet = true;
73 m_backupArn = std::forward<BackupArnT>(value);
74 }
75 template <typename BackupArnT = Aws::String>
76 Backup& WithBackupArn(BackupArnT&& value) {
77 SetBackupArn(std::forward<BackupArnT>(value));
78 return *this;
79 }
81
83
86 inline BackupState GetBackupState() const { return m_backupState; }
87 inline bool BackupStateHasBeenSet() const { return m_backupStateHasBeenSet; }
88 inline void SetBackupState(BackupState value) {
89 m_backupStateHasBeenSet = true;
90 m_backupState = value;
91 }
93 SetBackupState(value);
94 return *this;
95 }
97
99
102 inline const Aws::String& GetClusterId() const { return m_clusterId; }
103 inline bool ClusterIdHasBeenSet() const { return m_clusterIdHasBeenSet; }
104 template <typename ClusterIdT = Aws::String>
105 void SetClusterId(ClusterIdT&& value) {
106 m_clusterIdHasBeenSet = true;
107 m_clusterId = std::forward<ClusterIdT>(value);
108 }
109 template <typename ClusterIdT = Aws::String>
110 Backup& WithClusterId(ClusterIdT&& value) {
111 SetClusterId(std::forward<ClusterIdT>(value));
112 return *this;
113 }
115
117
120 inline const Aws::Utils::DateTime& GetCreateTimestamp() const { return m_createTimestamp; }
121 inline bool CreateTimestampHasBeenSet() const { return m_createTimestampHasBeenSet; }
122 template <typename CreateTimestampT = Aws::Utils::DateTime>
123 void SetCreateTimestamp(CreateTimestampT&& value) {
124 m_createTimestampHasBeenSet = true;
125 m_createTimestamp = std::forward<CreateTimestampT>(value);
126 }
127 template <typename CreateTimestampT = Aws::Utils::DateTime>
128 Backup& WithCreateTimestamp(CreateTimestampT&& value) {
129 SetCreateTimestamp(std::forward<CreateTimestampT>(value));
130 return *this;
131 }
133
135
138 inline const Aws::Utils::DateTime& GetCopyTimestamp() const { return m_copyTimestamp; }
139 inline bool CopyTimestampHasBeenSet() const { return m_copyTimestampHasBeenSet; }
140 template <typename CopyTimestampT = Aws::Utils::DateTime>
141 void SetCopyTimestamp(CopyTimestampT&& value) {
142 m_copyTimestampHasBeenSet = true;
143 m_copyTimestamp = std::forward<CopyTimestampT>(value);
144 }
145 template <typename CopyTimestampT = Aws::Utils::DateTime>
146 Backup& WithCopyTimestamp(CopyTimestampT&& value) {
147 SetCopyTimestamp(std::forward<CopyTimestampT>(value));
148 return *this;
149 }
151
153
159 inline bool GetNeverExpires() const { return m_neverExpires; }
160 inline bool NeverExpiresHasBeenSet() const { return m_neverExpiresHasBeenSet; }
161 inline void SetNeverExpires(bool value) {
162 m_neverExpiresHasBeenSet = true;
163 m_neverExpires = value;
164 }
165 inline Backup& WithNeverExpires(bool value) {
166 SetNeverExpires(value);
167 return *this;
168 }
170
172
176 inline const Aws::String& GetSourceRegion() const { return m_sourceRegion; }
177 inline bool SourceRegionHasBeenSet() const { return m_sourceRegionHasBeenSet; }
178 template <typename SourceRegionT = Aws::String>
179 void SetSourceRegion(SourceRegionT&& value) {
180 m_sourceRegionHasBeenSet = true;
181 m_sourceRegion = std::forward<SourceRegionT>(value);
182 }
183 template <typename SourceRegionT = Aws::String>
184 Backup& WithSourceRegion(SourceRegionT&& value) {
185 SetSourceRegion(std::forward<SourceRegionT>(value));
186 return *this;
187 }
189
191
195 inline const Aws::String& GetSourceBackup() const { return m_sourceBackup; }
196 inline bool SourceBackupHasBeenSet() const { return m_sourceBackupHasBeenSet; }
197 template <typename SourceBackupT = Aws::String>
198 void SetSourceBackup(SourceBackupT&& value) {
199 m_sourceBackupHasBeenSet = true;
200 m_sourceBackup = std::forward<SourceBackupT>(value);
201 }
202 template <typename SourceBackupT = Aws::String>
203 Backup& WithSourceBackup(SourceBackupT&& value) {
204 SetSourceBackup(std::forward<SourceBackupT>(value));
205 return *this;
206 }
208
210
214 inline const Aws::String& GetSourceCluster() const { return m_sourceCluster; }
215 inline bool SourceClusterHasBeenSet() const { return m_sourceClusterHasBeenSet; }
216 template <typename SourceClusterT = Aws::String>
217 void SetSourceCluster(SourceClusterT&& value) {
218 m_sourceClusterHasBeenSet = true;
219 m_sourceCluster = std::forward<SourceClusterT>(value);
220 }
221 template <typename SourceClusterT = Aws::String>
222 Backup& WithSourceCluster(SourceClusterT&& value) {
223 SetSourceCluster(std::forward<SourceClusterT>(value));
224 return *this;
225 }
227
229
232 inline const Aws::Utils::DateTime& GetDeleteTimestamp() const { return m_deleteTimestamp; }
233 inline bool DeleteTimestampHasBeenSet() const { return m_deleteTimestampHasBeenSet; }
234 template <typename DeleteTimestampT = Aws::Utils::DateTime>
235 void SetDeleteTimestamp(DeleteTimestampT&& value) {
236 m_deleteTimestampHasBeenSet = true;
237 m_deleteTimestamp = std::forward<DeleteTimestampT>(value);
238 }
239 template <typename DeleteTimestampT = Aws::Utils::DateTime>
240 Backup& WithDeleteTimestamp(DeleteTimestampT&& value) {
241 SetDeleteTimestamp(std::forward<DeleteTimestampT>(value));
242 return *this;
243 }
245
247
250 inline const Aws::Vector<Tag>& GetTagList() const { return m_tagList; }
251 inline bool TagListHasBeenSet() const { return m_tagListHasBeenSet; }
252 template <typename TagListT = Aws::Vector<Tag>>
253 void SetTagList(TagListT&& value) {
254 m_tagListHasBeenSet = true;
255 m_tagList = std::forward<TagListT>(value);
256 }
257 template <typename TagListT = Aws::Vector<Tag>>
258 Backup& WithTagList(TagListT&& value) {
259 SetTagList(std::forward<TagListT>(value));
260 return *this;
261 }
262 template <typename TagListT = Tag>
263 Backup& AddTagList(TagListT&& value) {
264 m_tagListHasBeenSet = true;
265 m_tagList.emplace_back(std::forward<TagListT>(value));
266 return *this;
267 }
269
271
274 inline const Aws::String& GetHsmType() const { return m_hsmType; }
275 inline bool HsmTypeHasBeenSet() const { return m_hsmTypeHasBeenSet; }
276 template <typename HsmTypeT = Aws::String>
277 void SetHsmType(HsmTypeT&& value) {
278 m_hsmTypeHasBeenSet = true;
279 m_hsmType = std::forward<HsmTypeT>(value);
280 }
281 template <typename HsmTypeT = Aws::String>
282 Backup& WithHsmType(HsmTypeT&& value) {
283 SetHsmType(std::forward<HsmTypeT>(value));
284 return *this;
285 }
287
289
292 inline ClusterMode GetMode() const { return m_mode; }
293 inline bool ModeHasBeenSet() const { return m_modeHasBeenSet; }
294 inline void SetMode(ClusterMode value) {
295 m_modeHasBeenSet = true;
296 m_mode = value;
297 }
298 inline Backup& WithMode(ClusterMode value) {
299 SetMode(value);
300 return *this;
301 }
303 private:
304 Aws::String m_backupId;
305
306 Aws::String m_backupArn;
307
308 BackupState m_backupState{BackupState::NOT_SET};
309
310 Aws::String m_clusterId;
311
312 Aws::Utils::DateTime m_createTimestamp{};
313
314 Aws::Utils::DateTime m_copyTimestamp{};
315
316 bool m_neverExpires{false};
317
318 Aws::String m_sourceRegion;
319
320 Aws::String m_sourceBackup;
321
322 Aws::String m_sourceCluster;
323
324 Aws::Utils::DateTime m_deleteTimestamp{};
325
326 Aws::Vector<Tag> m_tagList;
327
328 Aws::String m_hsmType;
329
331 bool m_backupIdHasBeenSet = false;
332 bool m_backupArnHasBeenSet = false;
333 bool m_backupStateHasBeenSet = false;
334 bool m_clusterIdHasBeenSet = false;
335 bool m_createTimestampHasBeenSet = false;
336 bool m_copyTimestampHasBeenSet = false;
337 bool m_neverExpiresHasBeenSet = false;
338 bool m_sourceRegionHasBeenSet = false;
339 bool m_sourceBackupHasBeenSet = false;
340 bool m_sourceClusterHasBeenSet = false;
341 bool m_deleteTimestampHasBeenSet = false;
342 bool m_tagListHasBeenSet = false;
343 bool m_hsmTypeHasBeenSet = false;
344 bool m_modeHasBeenSet = false;
345};
346
347} // namespace Model
348} // namespace CloudHSMV2
349} // namespace Aws
bool SourceRegionHasBeenSet() const
Definition Backup.h:177
Backup & WithSourceCluster(SourceClusterT &&value)
Definition Backup.h:222
bool ClusterIdHasBeenSet() const
Definition Backup.h:103
const Aws::String & GetSourceCluster() const
Definition Backup.h:214
void SetBackupId(BackupIdT &&value)
Definition Backup.h:53
void SetCopyTimestamp(CopyTimestampT &&value)
Definition Backup.h:141
Backup & WithDeleteTimestamp(DeleteTimestampT &&value)
Definition Backup.h:240
Backup & WithSourceBackup(SourceBackupT &&value)
Definition Backup.h:203
bool BackupIdHasBeenSet() const
Definition Backup.h:51
bool SourceClusterHasBeenSet() const
Definition Backup.h:215
void SetClusterId(ClusterIdT &&value)
Definition Backup.h:105
bool SourceBackupHasBeenSet() const
Definition Backup.h:196
void SetNeverExpires(bool value)
Definition Backup.h:161
const Aws::Utils::DateTime & GetDeleteTimestamp() const
Definition Backup.h:232
void SetSourceBackup(SourceBackupT &&value)
Definition Backup.h:198
const Aws::String & GetBackupArn() const
Definition Backup.h:68
Backup & WithClusterId(ClusterIdT &&value)
Definition Backup.h:110
Backup & WithCreateTimestamp(CreateTimestampT &&value)
Definition Backup.h:128
AWS_CLOUDHSMV2_API void CborEncode(Aws::Crt::Cbor::CborEncoder &encoder) const
AWS_CLOUDHSMV2_API Backup & operator=(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
bool NeverExpiresHasBeenSet() const
Definition Backup.h:160
const Aws::Utils::DateTime & GetCopyTimestamp() const
Definition Backup.h:138
Backup & WithNeverExpires(bool value)
Definition Backup.h:165
Backup & WithHsmType(HsmTypeT &&value)
Definition Backup.h:282
BackupState GetBackupState() const
Definition Backup.h:86
const Aws::Vector< Tag > & GetTagList() const
Definition Backup.h:250
void SetSourceRegion(SourceRegionT &&value)
Definition Backup.h:179
Backup & WithCopyTimestamp(CopyTimestampT &&value)
Definition Backup.h:146
void SetBackupArn(BackupArnT &&value)
Definition Backup.h:71
void SetSourceCluster(SourceClusterT &&value)
Definition Backup.h:217
Backup & WithBackupId(BackupIdT &&value)
Definition Backup.h:58
const Aws::String & GetBackupId() const
Definition Backup.h:50
Backup & WithBackupArn(BackupArnT &&value)
Definition Backup.h:76
const Aws::String & GetSourceBackup() const
Definition Backup.h:195
const Aws::String & GetClusterId() const
Definition Backup.h:102
Backup & WithMode(ClusterMode value)
Definition Backup.h:298
AWS_CLOUDHSMV2_API Backup()=default
ClusterMode GetMode() const
Definition Backup.h:292
void SetTagList(TagListT &&value)
Definition Backup.h:253
Backup & WithSourceRegion(SourceRegionT &&value)
Definition Backup.h:184
void SetMode(ClusterMode value)
Definition Backup.h:294
Backup & AddTagList(TagListT &&value)
Definition Backup.h:263
const Aws::String & GetSourceRegion() const
Definition Backup.h:176
bool HsmTypeHasBeenSet() const
Definition Backup.h:275
AWS_CLOUDHSMV2_API Backup(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
bool BackupArnHasBeenSet() const
Definition Backup.h:69
Backup & WithTagList(TagListT &&value)
Definition Backup.h:258
bool TagListHasBeenSet() const
Definition Backup.h:251
bool BackupStateHasBeenSet() const
Definition Backup.h:87
const Aws::String & GetHsmType() const
Definition Backup.h:274
bool DeleteTimestampHasBeenSet() const
Definition Backup.h:233
void SetCreateTimestamp(CreateTimestampT &&value)
Definition Backup.h:123
void SetHsmType(HsmTypeT &&value)
Definition Backup.h:277
void SetBackupState(BackupState value)
Definition Backup.h:88
bool CopyTimestampHasBeenSet() const
Definition Backup.h:139
Backup & WithBackupState(BackupState value)
Definition Backup.h:92
void SetDeleteTimestamp(DeleteTimestampT &&value)
Definition Backup.h:235
bool CreateTimestampHasBeenSet() const
Definition Backup.h:121
const Aws::Utils::DateTime & GetCreateTimestamp() const
Definition Backup.h:120
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector