AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
Backup.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/fsx/FSx_EXPORTS.h>
11#include <aws/fsx/model/ActiveDirectoryBackupAttributes.h>
12#include <aws/fsx/model/BackupFailureDetails.h>
13#include <aws/fsx/model/BackupLifecycle.h>
14#include <aws/fsx/model/BackupType.h>
15#include <aws/fsx/model/FileSystem.h>
16#include <aws/fsx/model/ResourceType.h>
17#include <aws/fsx/model/Tag.h>
18#include <aws/fsx/model/Volume.h>
19
20#include <utility>
21
22namespace Aws {
23namespace Utils {
24namespace Json {
25class JsonValue;
26class JsonView;
27} // namespace Json
28} // namespace Utils
29namespace FSx {
30namespace Model {
31
39class Backup {
40 public:
41 AWS_FSX_API Backup() = default;
42 AWS_FSX_API Backup(Aws::Utils::Json::JsonView jsonValue);
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
77 inline BackupLifecycle GetLifecycle() const { return m_lifecycle; }
78 inline bool LifecycleHasBeenSet() const { return m_lifecycleHasBeenSet; }
79 inline void SetLifecycle(BackupLifecycle value) {
80 m_lifecycleHasBeenSet = true;
81 m_lifecycle = value;
82 }
84 SetLifecycle(value);
85 return *this;
86 }
88
90
93 inline const BackupFailureDetails& GetFailureDetails() const { return m_failureDetails; }
94 inline bool FailureDetailsHasBeenSet() const { return m_failureDetailsHasBeenSet; }
95 template <typename FailureDetailsT = BackupFailureDetails>
96 void SetFailureDetails(FailureDetailsT&& value) {
97 m_failureDetailsHasBeenSet = true;
98 m_failureDetails = std::forward<FailureDetailsT>(value);
99 }
100 template <typename FailureDetailsT = BackupFailureDetails>
101 Backup& WithFailureDetails(FailureDetailsT&& value) {
102 SetFailureDetails(std::forward<FailureDetailsT>(value));
103 return *this;
104 }
106
108
111 inline BackupType GetType() const { return m_type; }
112 inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; }
113 inline void SetType(BackupType value) {
114 m_typeHasBeenSet = true;
115 m_type = value;
116 }
117 inline Backup& WithType(BackupType value) {
118 SetType(value);
119 return *this;
120 }
122
124
125 inline int GetProgressPercent() const { return m_progressPercent; }
126 inline bool ProgressPercentHasBeenSet() const { return m_progressPercentHasBeenSet; }
127 inline void SetProgressPercent(int value) {
128 m_progressPercentHasBeenSet = true;
129 m_progressPercent = value;
130 }
131 inline Backup& WithProgressPercent(int value) {
132 SetProgressPercent(value);
133 return *this;
134 }
136
138
141 inline const Aws::Utils::DateTime& GetCreationTime() const { return m_creationTime; }
142 inline bool CreationTimeHasBeenSet() const { return m_creationTimeHasBeenSet; }
143 template <typename CreationTimeT = Aws::Utils::DateTime>
144 void SetCreationTime(CreationTimeT&& value) {
145 m_creationTimeHasBeenSet = true;
146 m_creationTime = std::forward<CreationTimeT>(value);
147 }
148 template <typename CreationTimeT = Aws::Utils::DateTime>
149 Backup& WithCreationTime(CreationTimeT&& value) {
150 SetCreationTime(std::forward<CreationTimeT>(value));
151 return *this;
152 }
154
156
160 inline const Aws::String& GetKmsKeyId() const { return m_kmsKeyId; }
161 inline bool KmsKeyIdHasBeenSet() const { return m_kmsKeyIdHasBeenSet; }
162 template <typename KmsKeyIdT = Aws::String>
163 void SetKmsKeyId(KmsKeyIdT&& value) {
164 m_kmsKeyIdHasBeenSet = true;
165 m_kmsKeyId = std::forward<KmsKeyIdT>(value);
166 }
167 template <typename KmsKeyIdT = Aws::String>
168 Backup& WithKmsKeyId(KmsKeyIdT&& value) {
169 SetKmsKeyId(std::forward<KmsKeyIdT>(value));
170 return *this;
171 }
173
175
178 inline const Aws::String& GetResourceARN() const { return m_resourceARN; }
179 inline bool ResourceARNHasBeenSet() const { return m_resourceARNHasBeenSet; }
180 template <typename ResourceARNT = Aws::String>
181 void SetResourceARN(ResourceARNT&& value) {
182 m_resourceARNHasBeenSet = true;
183 m_resourceARN = std::forward<ResourceARNT>(value);
184 }
185 template <typename ResourceARNT = Aws::String>
186 Backup& WithResourceARN(ResourceARNT&& value) {
187 SetResourceARN(std::forward<ResourceARNT>(value));
188 return *this;
189 }
191
193
196 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
197 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
198 template <typename TagsT = Aws::Vector<Tag>>
199 void SetTags(TagsT&& value) {
200 m_tagsHasBeenSet = true;
201 m_tags = std::forward<TagsT>(value);
202 }
203 template <typename TagsT = Aws::Vector<Tag>>
204 Backup& WithTags(TagsT&& value) {
205 SetTags(std::forward<TagsT>(value));
206 return *this;
207 }
208 template <typename TagsT = Tag>
209 Backup& AddTags(TagsT&& value) {
210 m_tagsHasBeenSet = true;
211 m_tags.emplace_back(std::forward<TagsT>(value));
212 return *this;
213 }
215
217
221 inline const FileSystem& GetFileSystem() const { return m_fileSystem; }
222 inline bool FileSystemHasBeenSet() const { return m_fileSystemHasBeenSet; }
223 template <typename FileSystemT = FileSystem>
224 void SetFileSystem(FileSystemT&& value) {
225 m_fileSystemHasBeenSet = true;
226 m_fileSystem = std::forward<FileSystemT>(value);
227 }
228 template <typename FileSystemT = FileSystem>
229 Backup& WithFileSystem(FileSystemT&& value) {
230 SetFileSystem(std::forward<FileSystemT>(value));
231 return *this;
232 }
234
236
240 inline const ActiveDirectoryBackupAttributes& GetDirectoryInformation() const { return m_directoryInformation; }
241 inline bool DirectoryInformationHasBeenSet() const { return m_directoryInformationHasBeenSet; }
242 template <typename DirectoryInformationT = ActiveDirectoryBackupAttributes>
243 void SetDirectoryInformation(DirectoryInformationT&& value) {
244 m_directoryInformationHasBeenSet = true;
245 m_directoryInformation = std::forward<DirectoryInformationT>(value);
246 }
247 template <typename DirectoryInformationT = ActiveDirectoryBackupAttributes>
248 Backup& WithDirectoryInformation(DirectoryInformationT&& value) {
249 SetDirectoryInformation(std::forward<DirectoryInformationT>(value));
250 return *this;
251 }
253
255
256 inline const Aws::String& GetOwnerId() const { return m_ownerId; }
257 inline bool OwnerIdHasBeenSet() const { return m_ownerIdHasBeenSet; }
258 template <typename OwnerIdT = Aws::String>
259 void SetOwnerId(OwnerIdT&& value) {
260 m_ownerIdHasBeenSet = true;
261 m_ownerId = std::forward<OwnerIdT>(value);
262 }
263 template <typename OwnerIdT = Aws::String>
264 Backup& WithOwnerId(OwnerIdT&& value) {
265 SetOwnerId(std::forward<OwnerIdT>(value));
266 return *this;
267 }
269
271
272 inline const Aws::String& GetSourceBackupId() const { return m_sourceBackupId; }
273 inline bool SourceBackupIdHasBeenSet() const { return m_sourceBackupIdHasBeenSet; }
274 template <typename SourceBackupIdT = Aws::String>
275 void SetSourceBackupId(SourceBackupIdT&& value) {
276 m_sourceBackupIdHasBeenSet = true;
277 m_sourceBackupId = std::forward<SourceBackupIdT>(value);
278 }
279 template <typename SourceBackupIdT = Aws::String>
280 Backup& WithSourceBackupId(SourceBackupIdT&& value) {
281 SetSourceBackupId(std::forward<SourceBackupIdT>(value));
282 return *this;
283 }
285
287
291 inline const Aws::String& GetSourceBackupRegion() const { return m_sourceBackupRegion; }
292 inline bool SourceBackupRegionHasBeenSet() const { return m_sourceBackupRegionHasBeenSet; }
293 template <typename SourceBackupRegionT = Aws::String>
294 void SetSourceBackupRegion(SourceBackupRegionT&& value) {
295 m_sourceBackupRegionHasBeenSet = true;
296 m_sourceBackupRegion = std::forward<SourceBackupRegionT>(value);
297 }
298 template <typename SourceBackupRegionT = Aws::String>
299 Backup& WithSourceBackupRegion(SourceBackupRegionT&& value) {
300 SetSourceBackupRegion(std::forward<SourceBackupRegionT>(value));
301 return *this;
302 }
304
306
309 inline ResourceType GetResourceType() const { return m_resourceType; }
310 inline bool ResourceTypeHasBeenSet() const { return m_resourceTypeHasBeenSet; }
311 inline void SetResourceType(ResourceType value) {
312 m_resourceTypeHasBeenSet = true;
313 m_resourceType = value;
314 }
316 SetResourceType(value);
317 return *this;
318 }
320
322
323 inline const Volume& GetVolume() const { return m_volume; }
324 inline bool VolumeHasBeenSet() const { return m_volumeHasBeenSet; }
325 template <typename VolumeT = Volume>
326 void SetVolume(VolumeT&& value) {
327 m_volumeHasBeenSet = true;
328 m_volume = std::forward<VolumeT>(value);
329 }
330 template <typename VolumeT = Volume>
331 Backup& WithVolume(VolumeT&& value) {
332 SetVolume(std::forward<VolumeT>(value));
333 return *this;
334 }
336
338
342 inline long long GetSizeInBytes() const { return m_sizeInBytes; }
343 inline bool SizeInBytesHasBeenSet() const { return m_sizeInBytesHasBeenSet; }
344 inline void SetSizeInBytes(long long value) {
345 m_sizeInBytesHasBeenSet = true;
346 m_sizeInBytes = value;
347 }
348 inline Backup& WithSizeInBytes(long long value) {
349 SetSizeInBytes(value);
350 return *this;
351 }
353 private:
354 Aws::String m_backupId;
355
357
358 BackupFailureDetails m_failureDetails;
359
361
362 int m_progressPercent{0};
363
364 Aws::Utils::DateTime m_creationTime{};
365
366 Aws::String m_kmsKeyId;
367
368 Aws::String m_resourceARN;
369
370 Aws::Vector<Tag> m_tags;
371
372 FileSystem m_fileSystem;
373
374 ActiveDirectoryBackupAttributes m_directoryInformation;
375
376 Aws::String m_ownerId;
377
378 Aws::String m_sourceBackupId;
379
380 Aws::String m_sourceBackupRegion;
381
382 ResourceType m_resourceType{ResourceType::NOT_SET};
383
384 Volume m_volume;
385
386 long long m_sizeInBytes{0};
387 bool m_backupIdHasBeenSet = false;
388 bool m_lifecycleHasBeenSet = false;
389 bool m_failureDetailsHasBeenSet = false;
390 bool m_typeHasBeenSet = false;
391 bool m_progressPercentHasBeenSet = false;
392 bool m_creationTimeHasBeenSet = false;
393 bool m_kmsKeyIdHasBeenSet = false;
394 bool m_resourceARNHasBeenSet = false;
395 bool m_tagsHasBeenSet = false;
396 bool m_fileSystemHasBeenSet = false;
397 bool m_directoryInformationHasBeenSet = false;
398 bool m_ownerIdHasBeenSet = false;
399 bool m_sourceBackupIdHasBeenSet = false;
400 bool m_sourceBackupRegionHasBeenSet = false;
401 bool m_resourceTypeHasBeenSet = false;
402 bool m_volumeHasBeenSet = false;
403 bool m_sizeInBytesHasBeenSet = false;
404};
405
406} // namespace Model
407} // namespace FSx
408} // namespace Aws
const Aws::String & GetOwnerId() const
Definition Backup.h:256
Backup & AddTags(TagsT &&value)
Definition Backup.h:209
Backup & WithSourceBackupRegion(SourceBackupRegionT &&value)
Definition Backup.h:299
bool BackupIdHasBeenSet() const
Definition Backup.h:51
void SetFileSystem(FileSystemT &&value)
Definition Backup.h:224
Backup & WithResourceARN(ResourceARNT &&value)
Definition Backup.h:186
Backup & WithType(BackupType value)
Definition Backup.h:117
bool FileSystemHasBeenSet() const
Definition Backup.h:222
const Aws::Utils::DateTime & GetCreationTime() const
Definition Backup.h:141
const Aws::String & GetBackupId() const
Definition Backup.h:50
const Volume & GetVolume() const
Definition Backup.h:323
bool ResourceARNHasBeenSet() const
Definition Backup.h:179
const Aws::String & GetResourceARN() const
Definition Backup.h:178
Backup & WithFileSystem(FileSystemT &&value)
Definition Backup.h:229
Backup & WithResourceType(ResourceType value)
Definition Backup.h:315
const BackupFailureDetails & GetFailureDetails() const
Definition Backup.h:93
AWS_FSX_API Backup(Aws::Utils::Json::JsonView jsonValue)
Backup & WithVolume(VolumeT &&value)
Definition Backup.h:331
ResourceType GetResourceType() const
Definition Backup.h:309
const Aws::String & GetSourceBackupId() const
Definition Backup.h:272
bool FailureDetailsHasBeenSet() const
Definition Backup.h:94
const Aws::Vector< Tag > & GetTags() const
Definition Backup.h:196
bool LifecycleHasBeenSet() const
Definition Backup.h:78
void SetDirectoryInformation(DirectoryInformationT &&value)
Definition Backup.h:243
void SetType(BackupType value)
Definition Backup.h:113
void SetVolume(VolumeT &&value)
Definition Backup.h:326
bool OwnerIdHasBeenSet() const
Definition Backup.h:257
AWS_FSX_API Aws::Utils::Json::JsonValue Jsonize() const
bool TypeHasBeenSet() const
Definition Backup.h:112
void SetBackupId(BackupIdT &&value)
Definition Backup.h:53
Backup & WithDirectoryInformation(DirectoryInformationT &&value)
Definition Backup.h:248
bool VolumeHasBeenSet() const
Definition Backup.h:324
AWS_FSX_API Backup()=default
Backup & WithSourceBackupId(SourceBackupIdT &&value)
Definition Backup.h:280
Backup & WithFailureDetails(FailureDetailsT &&value)
Definition Backup.h:101
Backup & WithKmsKeyId(KmsKeyIdT &&value)
Definition Backup.h:168
bool ProgressPercentHasBeenSet() const
Definition Backup.h:126
BackupType GetType() const
Definition Backup.h:111
void SetSourceBackupRegion(SourceBackupRegionT &&value)
Definition Backup.h:294
void SetFailureDetails(FailureDetailsT &&value)
Definition Backup.h:96
bool ResourceTypeHasBeenSet() const
Definition Backup.h:310
bool SourceBackupRegionHasBeenSet() const
Definition Backup.h:292
Backup & WithBackupId(BackupIdT &&value)
Definition Backup.h:58
const FileSystem & GetFileSystem() const
Definition Backup.h:221
Backup & WithTags(TagsT &&value)
Definition Backup.h:204
Backup & WithOwnerId(OwnerIdT &&value)
Definition Backup.h:264
const Aws::String & GetSourceBackupRegion() const
Definition Backup.h:291
Backup & WithLifecycle(BackupLifecycle value)
Definition Backup.h:83
void SetSourceBackupId(SourceBackupIdT &&value)
Definition Backup.h:275
bool DirectoryInformationHasBeenSet() const
Definition Backup.h:241
void SetResourceType(ResourceType value)
Definition Backup.h:311
bool SizeInBytesHasBeenSet() const
Definition Backup.h:343
Backup & WithSizeInBytes(long long value)
Definition Backup.h:348
void SetCreationTime(CreationTimeT &&value)
Definition Backup.h:144
BackupLifecycle GetLifecycle() const
Definition Backup.h:77
bool CreationTimeHasBeenSet() const
Definition Backup.h:142
int GetProgressPercent() const
Definition Backup.h:125
void SetKmsKeyId(KmsKeyIdT &&value)
Definition Backup.h:163
Backup & WithCreationTime(CreationTimeT &&value)
Definition Backup.h:149
const ActiveDirectoryBackupAttributes & GetDirectoryInformation() const
Definition Backup.h:240
void SetSizeInBytes(long long value)
Definition Backup.h:344
bool TagsHasBeenSet() const
Definition Backup.h:197
const Aws::String & GetKmsKeyId() const
Definition Backup.h:160
void SetTags(TagsT &&value)
Definition Backup.h:199
long long GetSizeInBytes() const
Definition Backup.h:342
bool SourceBackupIdHasBeenSet() const
Definition Backup.h:273
void SetResourceARN(ResourceARNT &&value)
Definition Backup.h:181
bool KmsKeyIdHasBeenSet() const
Definition Backup.h:161
void SetProgressPercent(int value)
Definition Backup.h:127
Backup & WithProgressPercent(int value)
Definition Backup.h:131
void SetOwnerId(OwnerIdT &&value)
Definition Backup.h:259
void SetLifecycle(BackupLifecycle value)
Definition Backup.h:79
AWS_FSX_API Backup & operator=(Aws::Utils::Json::JsonView jsonValue)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue