AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
InstanceSnapshot.h
1
6#pragma once
7#include <aws/lightsail/Lightsail_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/DateTime.h>
10#include <aws/lightsail/model/ResourceLocation.h>
11#include <aws/lightsail/model/ResourceType.h>
12#include <aws/core/utils/memory/stl/AWSVector.h>
13#include <aws/lightsail/model/InstanceSnapshotState.h>
14#include <aws/lightsail/model/Tag.h>
15#include <aws/lightsail/model/Disk.h>
16#include <utility>
17
18namespace Aws
19{
20namespace Utils
21{
22namespace Json
23{
24 class JsonValue;
25 class JsonView;
26} // namespace Json
27} // namespace Utils
28namespace Lightsail
29{
30namespace Model
31{
32
39 {
40 public:
41 AWS_LIGHTSAIL_API InstanceSnapshot();
42 AWS_LIGHTSAIL_API InstanceSnapshot(Aws::Utils::Json::JsonView jsonValue);
44 AWS_LIGHTSAIL_API Aws::Utils::Json::JsonValue Jsonize() const;
45
46
48
51 inline const Aws::String& GetName() const{ return m_name; }
52 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
53 inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; }
54 inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); }
55 inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); }
56 inline InstanceSnapshot& WithName(const Aws::String& value) { SetName(value); return *this;}
57 inline InstanceSnapshot& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;}
58 inline InstanceSnapshot& WithName(const char* value) { SetName(value); return *this;}
60
62
66 inline const Aws::String& GetArn() const{ return m_arn; }
67 inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; }
68 inline void SetArn(const Aws::String& value) { m_arnHasBeenSet = true; m_arn = value; }
69 inline void SetArn(Aws::String&& value) { m_arnHasBeenSet = true; m_arn = std::move(value); }
70 inline void SetArn(const char* value) { m_arnHasBeenSet = true; m_arn.assign(value); }
71 inline InstanceSnapshot& WithArn(const Aws::String& value) { SetArn(value); return *this;}
72 inline InstanceSnapshot& WithArn(Aws::String&& value) { SetArn(std::move(value)); return *this;}
73 inline InstanceSnapshot& WithArn(const char* value) { SetArn(value); return *this;}
75
77
82 inline const Aws::String& GetSupportCode() const{ return m_supportCode; }
83 inline bool SupportCodeHasBeenSet() const { return m_supportCodeHasBeenSet; }
84 inline void SetSupportCode(const Aws::String& value) { m_supportCodeHasBeenSet = true; m_supportCode = value; }
85 inline void SetSupportCode(Aws::String&& value) { m_supportCodeHasBeenSet = true; m_supportCode = std::move(value); }
86 inline void SetSupportCode(const char* value) { m_supportCodeHasBeenSet = true; m_supportCode.assign(value); }
87 inline InstanceSnapshot& WithSupportCode(const Aws::String& value) { SetSupportCode(value); return *this;}
88 inline InstanceSnapshot& WithSupportCode(Aws::String&& value) { SetSupportCode(std::move(value)); return *this;}
89 inline InstanceSnapshot& WithSupportCode(const char* value) { SetSupportCode(value); return *this;}
91
93
97 inline const Aws::Utils::DateTime& GetCreatedAt() const{ return m_createdAt; }
98 inline bool CreatedAtHasBeenSet() const { return m_createdAtHasBeenSet; }
99 inline void SetCreatedAt(const Aws::Utils::DateTime& value) { m_createdAtHasBeenSet = true; m_createdAt = value; }
100 inline void SetCreatedAt(Aws::Utils::DateTime&& value) { m_createdAtHasBeenSet = true; m_createdAt = std::move(value); }
101 inline InstanceSnapshot& WithCreatedAt(const Aws::Utils::DateTime& value) { SetCreatedAt(value); return *this;}
102 inline InstanceSnapshot& WithCreatedAt(Aws::Utils::DateTime&& value) { SetCreatedAt(std::move(value)); return *this;}
104
106
109 inline const ResourceLocation& GetLocation() const{ return m_location; }
110 inline bool LocationHasBeenSet() const { return m_locationHasBeenSet; }
111 inline void SetLocation(const ResourceLocation& value) { m_locationHasBeenSet = true; m_location = value; }
112 inline void SetLocation(ResourceLocation&& value) { m_locationHasBeenSet = true; m_location = std::move(value); }
113 inline InstanceSnapshot& WithLocation(const ResourceLocation& value) { SetLocation(value); return *this;}
114 inline InstanceSnapshot& WithLocation(ResourceLocation&& value) { SetLocation(std::move(value)); return *this;}
116
118
121 inline const ResourceType& GetResourceType() const{ return m_resourceType; }
122 inline bool ResourceTypeHasBeenSet() const { return m_resourceTypeHasBeenSet; }
123 inline void SetResourceType(const ResourceType& value) { m_resourceTypeHasBeenSet = true; m_resourceType = value; }
124 inline void SetResourceType(ResourceType&& value) { m_resourceTypeHasBeenSet = true; m_resourceType = std::move(value); }
125 inline InstanceSnapshot& WithResourceType(const ResourceType& value) { SetResourceType(value); return *this;}
126 inline InstanceSnapshot& WithResourceType(ResourceType&& value) { SetResourceType(std::move(value)); return *this;}
128
130
136 inline const Aws::Vector<Tag>& GetTags() const{ return m_tags; }
137 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
138 inline void SetTags(const Aws::Vector<Tag>& value) { m_tagsHasBeenSet = true; m_tags = value; }
139 inline void SetTags(Aws::Vector<Tag>&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); }
140 inline InstanceSnapshot& WithTags(const Aws::Vector<Tag>& value) { SetTags(value); return *this;}
141 inline InstanceSnapshot& WithTags(Aws::Vector<Tag>&& value) { SetTags(std::move(value)); return *this;}
142 inline InstanceSnapshot& AddTags(const Tag& value) { m_tagsHasBeenSet = true; m_tags.push_back(value); return *this; }
143 inline InstanceSnapshot& AddTags(Tag&& value) { m_tagsHasBeenSet = true; m_tags.push_back(std::move(value)); return *this; }
145
147
150 inline const InstanceSnapshotState& GetState() const{ return m_state; }
151 inline bool StateHasBeenSet() const { return m_stateHasBeenSet; }
152 inline void SetState(const InstanceSnapshotState& value) { m_stateHasBeenSet = true; m_state = value; }
153 inline void SetState(InstanceSnapshotState&& value) { m_stateHasBeenSet = true; m_state = std::move(value); }
154 inline InstanceSnapshot& WithState(const InstanceSnapshotState& value) { SetState(value); return *this;}
155 inline InstanceSnapshot& WithState(InstanceSnapshotState&& value) { SetState(std::move(value)); return *this;}
157
159
163 inline const Aws::String& GetProgress() const{ return m_progress; }
164 inline bool ProgressHasBeenSet() const { return m_progressHasBeenSet; }
165 inline void SetProgress(const Aws::String& value) { m_progressHasBeenSet = true; m_progress = value; }
166 inline void SetProgress(Aws::String&& value) { m_progressHasBeenSet = true; m_progress = std::move(value); }
167 inline void SetProgress(const char* value) { m_progressHasBeenSet = true; m_progress.assign(value); }
168 inline InstanceSnapshot& WithProgress(const Aws::String& value) { SetProgress(value); return *this;}
169 inline InstanceSnapshot& WithProgress(Aws::String&& value) { SetProgress(std::move(value)); return *this;}
170 inline InstanceSnapshot& WithProgress(const char* value) { SetProgress(value); return *this;}
172
174
178 inline const Aws::Vector<Disk>& GetFromAttachedDisks() const{ return m_fromAttachedDisks; }
179 inline bool FromAttachedDisksHasBeenSet() const { return m_fromAttachedDisksHasBeenSet; }
180 inline void SetFromAttachedDisks(const Aws::Vector<Disk>& value) { m_fromAttachedDisksHasBeenSet = true; m_fromAttachedDisks = value; }
181 inline void SetFromAttachedDisks(Aws::Vector<Disk>&& value) { m_fromAttachedDisksHasBeenSet = true; m_fromAttachedDisks = std::move(value); }
183 inline InstanceSnapshot& WithFromAttachedDisks(Aws::Vector<Disk>&& value) { SetFromAttachedDisks(std::move(value)); return *this;}
184 inline InstanceSnapshot& AddFromAttachedDisks(const Disk& value) { m_fromAttachedDisksHasBeenSet = true; m_fromAttachedDisks.push_back(value); return *this; }
185 inline InstanceSnapshot& AddFromAttachedDisks(Disk&& value) { m_fromAttachedDisksHasBeenSet = true; m_fromAttachedDisks.push_back(std::move(value)); return *this; }
187
189
192 inline const Aws::String& GetFromInstanceName() const{ return m_fromInstanceName; }
193 inline bool FromInstanceNameHasBeenSet() const { return m_fromInstanceNameHasBeenSet; }
194 inline void SetFromInstanceName(const Aws::String& value) { m_fromInstanceNameHasBeenSet = true; m_fromInstanceName = value; }
195 inline void SetFromInstanceName(Aws::String&& value) { m_fromInstanceNameHasBeenSet = true; m_fromInstanceName = std::move(value); }
196 inline void SetFromInstanceName(const char* value) { m_fromInstanceNameHasBeenSet = true; m_fromInstanceName.assign(value); }
197 inline InstanceSnapshot& WithFromInstanceName(const Aws::String& value) { SetFromInstanceName(value); return *this;}
198 inline InstanceSnapshot& WithFromInstanceName(Aws::String&& value) { SetFromInstanceName(std::move(value)); return *this;}
199 inline InstanceSnapshot& WithFromInstanceName(const char* value) { SetFromInstanceName(value); return *this;}
201
203
208 inline const Aws::String& GetFromInstanceArn() const{ return m_fromInstanceArn; }
209 inline bool FromInstanceArnHasBeenSet() const { return m_fromInstanceArnHasBeenSet; }
210 inline void SetFromInstanceArn(const Aws::String& value) { m_fromInstanceArnHasBeenSet = true; m_fromInstanceArn = value; }
211 inline void SetFromInstanceArn(Aws::String&& value) { m_fromInstanceArnHasBeenSet = true; m_fromInstanceArn = std::move(value); }
212 inline void SetFromInstanceArn(const char* value) { m_fromInstanceArnHasBeenSet = true; m_fromInstanceArn.assign(value); }
213 inline InstanceSnapshot& WithFromInstanceArn(const Aws::String& value) { SetFromInstanceArn(value); return *this;}
214 inline InstanceSnapshot& WithFromInstanceArn(Aws::String&& value) { SetFromInstanceArn(std::move(value)); return *this;}
215 inline InstanceSnapshot& WithFromInstanceArn(const char* value) { SetFromInstanceArn(value); return *this;}
217
219
224 inline const Aws::String& GetFromBlueprintId() const{ return m_fromBlueprintId; }
225 inline bool FromBlueprintIdHasBeenSet() const { return m_fromBlueprintIdHasBeenSet; }
226 inline void SetFromBlueprintId(const Aws::String& value) { m_fromBlueprintIdHasBeenSet = true; m_fromBlueprintId = value; }
227 inline void SetFromBlueprintId(Aws::String&& value) { m_fromBlueprintIdHasBeenSet = true; m_fromBlueprintId = std::move(value); }
228 inline void SetFromBlueprintId(const char* value) { m_fromBlueprintIdHasBeenSet = true; m_fromBlueprintId.assign(value); }
229 inline InstanceSnapshot& WithFromBlueprintId(const Aws::String& value) { SetFromBlueprintId(value); return *this;}
230 inline InstanceSnapshot& WithFromBlueprintId(Aws::String&& value) { SetFromBlueprintId(std::move(value)); return *this;}
231 inline InstanceSnapshot& WithFromBlueprintId(const char* value) { SetFromBlueprintId(value); return *this;}
233
235
239 inline const Aws::String& GetFromBundleId() const{ return m_fromBundleId; }
240 inline bool FromBundleIdHasBeenSet() const { return m_fromBundleIdHasBeenSet; }
241 inline void SetFromBundleId(const Aws::String& value) { m_fromBundleIdHasBeenSet = true; m_fromBundleId = value; }
242 inline void SetFromBundleId(Aws::String&& value) { m_fromBundleIdHasBeenSet = true; m_fromBundleId = std::move(value); }
243 inline void SetFromBundleId(const char* value) { m_fromBundleIdHasBeenSet = true; m_fromBundleId.assign(value); }
244 inline InstanceSnapshot& WithFromBundleId(const Aws::String& value) { SetFromBundleId(value); return *this;}
245 inline InstanceSnapshot& WithFromBundleId(Aws::String&& value) { SetFromBundleId(std::move(value)); return *this;}
246 inline InstanceSnapshot& WithFromBundleId(const char* value) { SetFromBundleId(value); return *this;}
248
250
254 inline bool GetIsFromAutoSnapshot() const{ return m_isFromAutoSnapshot; }
255 inline bool IsFromAutoSnapshotHasBeenSet() const { return m_isFromAutoSnapshotHasBeenSet; }
256 inline void SetIsFromAutoSnapshot(bool value) { m_isFromAutoSnapshotHasBeenSet = true; m_isFromAutoSnapshot = value; }
257 inline InstanceSnapshot& WithIsFromAutoSnapshot(bool value) { SetIsFromAutoSnapshot(value); return *this;}
259
261
264 inline int GetSizeInGb() const{ return m_sizeInGb; }
265 inline bool SizeInGbHasBeenSet() const { return m_sizeInGbHasBeenSet; }
266 inline void SetSizeInGb(int value) { m_sizeInGbHasBeenSet = true; m_sizeInGb = value; }
267 inline InstanceSnapshot& WithSizeInGb(int value) { SetSizeInGb(value); return *this;}
269 private:
270
271 Aws::String m_name;
272 bool m_nameHasBeenSet = false;
273
274 Aws::String m_arn;
275 bool m_arnHasBeenSet = false;
276
277 Aws::String m_supportCode;
278 bool m_supportCodeHasBeenSet = false;
279
280 Aws::Utils::DateTime m_createdAt;
281 bool m_createdAtHasBeenSet = false;
282
283 ResourceLocation m_location;
284 bool m_locationHasBeenSet = false;
285
286 ResourceType m_resourceType;
287 bool m_resourceTypeHasBeenSet = false;
288
289 Aws::Vector<Tag> m_tags;
290 bool m_tagsHasBeenSet = false;
291
292 InstanceSnapshotState m_state;
293 bool m_stateHasBeenSet = false;
294
295 Aws::String m_progress;
296 bool m_progressHasBeenSet = false;
297
298 Aws::Vector<Disk> m_fromAttachedDisks;
299 bool m_fromAttachedDisksHasBeenSet = false;
300
301 Aws::String m_fromInstanceName;
302 bool m_fromInstanceNameHasBeenSet = false;
303
304 Aws::String m_fromInstanceArn;
305 bool m_fromInstanceArnHasBeenSet = false;
306
307 Aws::String m_fromBlueprintId;
308 bool m_fromBlueprintIdHasBeenSet = false;
309
310 Aws::String m_fromBundleId;
311 bool m_fromBundleIdHasBeenSet = false;
312
313 bool m_isFromAutoSnapshot;
314 bool m_isFromAutoSnapshotHasBeenSet = false;
315
316 int m_sizeInGb;
317 bool m_sizeInGbHasBeenSet = false;
318 };
319
320} // namespace Model
321} // namespace Lightsail
322} // namespace Aws
const ResourceType & GetResourceType() const
InstanceSnapshot & AddFromAttachedDisks(Disk &&value)
void SetFromAttachedDisks(Aws::Vector< Disk > &&value)
InstanceSnapshot & WithFromAttachedDisks(Aws::Vector< Disk > &&value)
const Aws::String & GetProgress() const
InstanceSnapshot & WithProgress(const char *value)
InstanceSnapshot & WithFromInstanceArn(const char *value)
AWS_LIGHTSAIL_API InstanceSnapshot & operator=(Aws::Utils::Json::JsonView jsonValue)
InstanceSnapshot & WithFromInstanceArn(Aws::String &&value)
InstanceSnapshot & WithFromInstanceName(const Aws::String &value)
InstanceSnapshot & WithLocation(ResourceLocation &&value)
InstanceSnapshot & WithFromInstanceName(const char *value)
InstanceSnapshot & WithArn(Aws::String &&value)
InstanceSnapshot & WithIsFromAutoSnapshot(bool value)
void SetFromInstanceArn(const Aws::String &value)
void SetSupportCode(Aws::String &&value)
InstanceSnapshot & WithFromBundleId(const Aws::String &value)
void SetFromInstanceName(const Aws::String &value)
InstanceSnapshot & AddFromAttachedDisks(const Disk &value)
const ResourceLocation & GetLocation() const
AWS_LIGHTSAIL_API InstanceSnapshot(Aws::Utils::Json::JsonView jsonValue)
const Aws::String & GetName() const
InstanceSnapshot & WithState(const InstanceSnapshotState &value)
InstanceSnapshot & AddTags(Tag &&value)
InstanceSnapshot & WithArn(const Aws::String &value)
InstanceSnapshot & WithFromBundleId(const char *value)
const Aws::String & GetSupportCode() const
void SetTags(const Aws::Vector< Tag > &value)
InstanceSnapshot & WithProgress(const Aws::String &value)
void SetState(InstanceSnapshotState &&value)
InstanceSnapshot & WithFromBlueprintId(Aws::String &&value)
InstanceSnapshot & WithArn(const char *value)
InstanceSnapshot & WithCreatedAt(Aws::Utils::DateTime &&value)
InstanceSnapshot & WithCreatedAt(const Aws::Utils::DateTime &value)
void SetState(const InstanceSnapshotState &value)
void SetArn(const Aws::String &value)
void SetTags(Aws::Vector< Tag > &&value)
void SetName(const Aws::String &value)
InstanceSnapshot & WithFromInstanceName(Aws::String &&value)
void SetCreatedAt(const Aws::Utils::DateTime &value)
void SetLocation(ResourceLocation &&value)
void SetFromBundleId(const Aws::String &value)
InstanceSnapshot & WithName(const Aws::String &value)
void SetResourceType(ResourceType &&value)
void SetFromAttachedDisks(const Aws::Vector< Disk > &value)
void SetFromBundleId(Aws::String &&value)
void SetCreatedAt(Aws::Utils::DateTime &&value)
void SetResourceType(const ResourceType &value)
InstanceSnapshot & WithFromAttachedDisks(const Aws::Vector< Disk > &value)
InstanceSnapshot & WithProgress(Aws::String &&value)
InstanceSnapshot & WithName(const char *value)
InstanceSnapshot & WithResourceType(const ResourceType &value)
InstanceSnapshot & WithResourceType(ResourceType &&value)
InstanceSnapshot & WithSizeInGb(int value)
void SetFromBlueprintId(Aws::String &&value)
InstanceSnapshot & WithSupportCode(Aws::String &&value)
InstanceSnapshot & WithTags(Aws::Vector< Tag > &&value)
const InstanceSnapshotState & GetState() const
void SetSupportCode(const Aws::String &value)
InstanceSnapshot & WithFromBundleId(Aws::String &&value)
InstanceSnapshot & WithFromInstanceArn(const Aws::String &value)
void SetFromBlueprintId(const Aws::String &value)
void SetFromInstanceName(Aws::String &&value)
void SetLocation(const ResourceLocation &value)
InstanceSnapshot & WithName(Aws::String &&value)
AWS_LIGHTSAIL_API Aws::Utils::Json::JsonValue Jsonize() const
InstanceSnapshot & AddTags(const Tag &value)
void SetProgress(const Aws::String &value)
InstanceSnapshot & WithSupportCode(const Aws::String &value)
InstanceSnapshot & WithFromBlueprintId(const Aws::String &value)
const Aws::String & GetFromInstanceName() const
const Aws::Utils::DateTime & GetCreatedAt() const
const Aws::Vector< Tag > & GetTags() const
InstanceSnapshot & WithState(InstanceSnapshotState &&value)
const Aws::String & GetFromBundleId() const
const Aws::String & GetFromInstanceArn() const
InstanceSnapshot & WithFromBlueprintId(const char *value)
const Aws::String & GetFromBlueprintId() const
const Aws::Vector< Disk > & GetFromAttachedDisks() const
InstanceSnapshot & WithLocation(const ResourceLocation &value)
void SetFromInstanceArn(Aws::String &&value)
InstanceSnapshot & WithTags(const Aws::Vector< Tag > &value)
InstanceSnapshot & WithSupportCode(const char *value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue