AWS SDK for C++

AWS SDK for C++ Version 1.11.717

Loading...
Searching...
No Matches
CopyImageRequest.h
1
6#pragma once
7#include <aws/core/utils/UUID.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/ec2/EC2Request.h>
11#include <aws/ec2/EC2_EXPORTS.h>
12#include <aws/ec2/model/TagSpecification.h>
13
14#include <utility>
15
16namespace Aws {
17namespace EC2 {
18namespace Model {
19
26 public:
27 AWS_EC2_API CopyImageRequest() = 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 "CopyImage"; }
34
35 AWS_EC2_API Aws::String SerializePayload() const override;
36
37 protected:
38 AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI& uri) const override;
39
40 public:
42
49 inline const Aws::String& GetClientToken() const { return m_clientToken; }
50 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
51 template <typename ClientTokenT = Aws::String>
52 void SetClientToken(ClientTokenT&& value) {
53 m_clientTokenHasBeenSet = true;
54 m_clientToken = std::forward<ClientTokenT>(value);
55 }
56 template <typename ClientTokenT = Aws::String>
57 CopyImageRequest& WithClientToken(ClientTokenT&& value) {
58 SetClientToken(std::forward<ClientTokenT>(value));
59 return *this;
60 }
62
64
67 inline const Aws::String& GetDescription() const { return m_description; }
68 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
69 template <typename DescriptionT = Aws::String>
70 void SetDescription(DescriptionT&& value) {
71 m_descriptionHasBeenSet = true;
72 m_description = std::forward<DescriptionT>(value);
73 }
74 template <typename DescriptionT = Aws::String>
75 CopyImageRequest& WithDescription(DescriptionT&& value) {
76 SetDescription(std::forward<DescriptionT>(value));
77 return *this;
78 }
80
82
91 inline bool GetEncrypted() const { return m_encrypted; }
92 inline bool EncryptedHasBeenSet() const { return m_encryptedHasBeenSet; }
93 inline void SetEncrypted(bool value) {
94 m_encryptedHasBeenSet = true;
95 m_encrypted = value;
96 }
97 inline CopyImageRequest& WithEncrypted(bool value) {
98 SetEncrypted(value);
99 return *this;
100 }
102
104
120 inline const Aws::String& GetKmsKeyId() const { return m_kmsKeyId; }
121 inline bool KmsKeyIdHasBeenSet() const { return m_kmsKeyIdHasBeenSet; }
122 template <typename KmsKeyIdT = Aws::String>
123 void SetKmsKeyId(KmsKeyIdT&& value) {
124 m_kmsKeyIdHasBeenSet = true;
125 m_kmsKeyId = std::forward<KmsKeyIdT>(value);
126 }
127 template <typename KmsKeyIdT = Aws::String>
128 CopyImageRequest& WithKmsKeyId(KmsKeyIdT&& value) {
129 SetKmsKeyId(std::forward<KmsKeyIdT>(value));
130 return *this;
131 }
133
135
138 inline const Aws::String& GetName() const { return m_name; }
139 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
140 template <typename NameT = Aws::String>
141 void SetName(NameT&& value) {
142 m_nameHasBeenSet = true;
143 m_name = std::forward<NameT>(value);
144 }
145 template <typename NameT = Aws::String>
146 CopyImageRequest& WithName(NameT&& value) {
147 SetName(std::forward<NameT>(value));
148 return *this;
149 }
151
153
156 inline const Aws::String& GetSourceImageId() const { return m_sourceImageId; }
157 inline bool SourceImageIdHasBeenSet() const { return m_sourceImageIdHasBeenSet; }
158 template <typename SourceImageIdT = Aws::String>
159 void SetSourceImageId(SourceImageIdT&& value) {
160 m_sourceImageIdHasBeenSet = true;
161 m_sourceImageId = std::forward<SourceImageIdT>(value);
162 }
163 template <typename SourceImageIdT = Aws::String>
164 CopyImageRequest& WithSourceImageId(SourceImageIdT&& value) {
165 SetSourceImageId(std::forward<SourceImageIdT>(value));
166 return *this;
167 }
169
171
174 inline const Aws::String& GetSourceRegion() const { return m_sourceRegion; }
175 inline bool SourceRegionHasBeenSet() const { return m_sourceRegionHasBeenSet; }
176 template <typename SourceRegionT = Aws::String>
177 void SetSourceRegion(SourceRegionT&& value) {
178 m_sourceRegionHasBeenSet = true;
179 m_sourceRegion = std::forward<SourceRegionT>(value);
180 }
181 template <typename SourceRegionT = Aws::String>
182 CopyImageRequest& WithSourceRegion(SourceRegionT&& value) {
183 SetSourceRegion(std::forward<SourceRegionT>(value));
184 return *this;
185 }
187
189
201 inline const Aws::String& GetDestinationOutpostArn() const { return m_destinationOutpostArn; }
202 inline bool DestinationOutpostArnHasBeenSet() const { return m_destinationOutpostArnHasBeenSet; }
203 template <typename DestinationOutpostArnT = Aws::String>
204 void SetDestinationOutpostArn(DestinationOutpostArnT&& value) {
205 m_destinationOutpostArnHasBeenSet = true;
206 m_destinationOutpostArn = std::forward<DestinationOutpostArnT>(value);
207 }
208 template <typename DestinationOutpostArnT = Aws::String>
209 CopyImageRequest& WithDestinationOutpostArn(DestinationOutpostArnT&& value) {
210 SetDestinationOutpostArn(std::forward<DestinationOutpostArnT>(value));
211 return *this;
212 }
214
216
223 inline bool GetCopyImageTags() const { return m_copyImageTags; }
224 inline bool CopyImageTagsHasBeenSet() const { return m_copyImageTagsHasBeenSet; }
225 inline void SetCopyImageTags(bool value) {
226 m_copyImageTagsHasBeenSet = true;
227 m_copyImageTags = value;
228 }
230 SetCopyImageTags(value);
231 return *this;
232 }
234
236
247 inline const Aws::Vector<TagSpecification>& GetTagSpecifications() const { return m_tagSpecifications; }
248 inline bool TagSpecificationsHasBeenSet() const { return m_tagSpecificationsHasBeenSet; }
249 template <typename TagSpecificationsT = Aws::Vector<TagSpecification>>
250 void SetTagSpecifications(TagSpecificationsT&& value) {
251 m_tagSpecificationsHasBeenSet = true;
252 m_tagSpecifications = std::forward<TagSpecificationsT>(value);
253 }
254 template <typename TagSpecificationsT = Aws::Vector<TagSpecification>>
255 CopyImageRequest& WithTagSpecifications(TagSpecificationsT&& value) {
256 SetTagSpecifications(std::forward<TagSpecificationsT>(value));
257 return *this;
258 }
259 template <typename TagSpecificationsT = TagSpecification>
260 CopyImageRequest& AddTagSpecifications(TagSpecificationsT&& value) {
261 m_tagSpecificationsHasBeenSet = true;
262 m_tagSpecifications.emplace_back(std::forward<TagSpecificationsT>(value));
263 return *this;
264 }
266
268
281 inline long long GetSnapshotCopyCompletionDurationMinutes() const { return m_snapshotCopyCompletionDurationMinutes; }
282 inline bool SnapshotCopyCompletionDurationMinutesHasBeenSet() const { return m_snapshotCopyCompletionDurationMinutesHasBeenSet; }
283 inline void SetSnapshotCopyCompletionDurationMinutes(long long value) {
284 m_snapshotCopyCompletionDurationMinutesHasBeenSet = true;
285 m_snapshotCopyCompletionDurationMinutes = value;
286 }
289 return *this;
290 }
292
294
301 inline const Aws::String& GetDestinationAvailabilityZone() const { return m_destinationAvailabilityZone; }
302 inline bool DestinationAvailabilityZoneHasBeenSet() const { return m_destinationAvailabilityZoneHasBeenSet; }
303 template <typename DestinationAvailabilityZoneT = Aws::String>
304 void SetDestinationAvailabilityZone(DestinationAvailabilityZoneT&& value) {
305 m_destinationAvailabilityZoneHasBeenSet = true;
306 m_destinationAvailabilityZone = std::forward<DestinationAvailabilityZoneT>(value);
307 }
308 template <typename DestinationAvailabilityZoneT = Aws::String>
309 CopyImageRequest& WithDestinationAvailabilityZone(DestinationAvailabilityZoneT&& value) {
310 SetDestinationAvailabilityZone(std::forward<DestinationAvailabilityZoneT>(value));
311 return *this;
312 }
314
316
323 inline const Aws::String& GetDestinationAvailabilityZoneId() const { return m_destinationAvailabilityZoneId; }
324 inline bool DestinationAvailabilityZoneIdHasBeenSet() const { return m_destinationAvailabilityZoneIdHasBeenSet; }
325 template <typename DestinationAvailabilityZoneIdT = Aws::String>
326 void SetDestinationAvailabilityZoneId(DestinationAvailabilityZoneIdT&& value) {
327 m_destinationAvailabilityZoneIdHasBeenSet = true;
328 m_destinationAvailabilityZoneId = std::forward<DestinationAvailabilityZoneIdT>(value);
329 }
330 template <typename DestinationAvailabilityZoneIdT = Aws::String>
331 CopyImageRequest& WithDestinationAvailabilityZoneId(DestinationAvailabilityZoneIdT&& value) {
332 SetDestinationAvailabilityZoneId(std::forward<DestinationAvailabilityZoneIdT>(value));
333 return *this;
334 }
336
338
344 inline bool GetDryRun() const { return m_dryRun; }
345 inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; }
346 inline void SetDryRun(bool value) {
347 m_dryRunHasBeenSet = true;
348 m_dryRun = value;
349 }
350 inline CopyImageRequest& WithDryRun(bool value) {
351 SetDryRun(value);
352 return *this;
353 }
355 private:
357
358 Aws::String m_description;
359
360 bool m_encrypted{false};
361
362 Aws::String m_kmsKeyId;
363
364 Aws::String m_name;
365
366 Aws::String m_sourceImageId;
367
368 Aws::String m_sourceRegion;
369
370 Aws::String m_destinationOutpostArn;
371
372 bool m_copyImageTags{false};
373
374 Aws::Vector<TagSpecification> m_tagSpecifications;
375
376 long long m_snapshotCopyCompletionDurationMinutes{0};
377
378 Aws::String m_destinationAvailabilityZone;
379
380 Aws::String m_destinationAvailabilityZoneId;
381
382 bool m_dryRun{false};
383 bool m_clientTokenHasBeenSet = true;
384 bool m_descriptionHasBeenSet = false;
385 bool m_encryptedHasBeenSet = false;
386 bool m_kmsKeyIdHasBeenSet = false;
387 bool m_nameHasBeenSet = false;
388 bool m_sourceImageIdHasBeenSet = false;
389 bool m_sourceRegionHasBeenSet = false;
390 bool m_destinationOutpostArnHasBeenSet = false;
391 bool m_copyImageTagsHasBeenSet = false;
392 bool m_tagSpecificationsHasBeenSet = false;
393 bool m_snapshotCopyCompletionDurationMinutesHasBeenSet = false;
394 bool m_destinationAvailabilityZoneHasBeenSet = false;
395 bool m_destinationAvailabilityZoneIdHasBeenSet = false;
396 bool m_dryRunHasBeenSet = false;
397};
398
399} // namespace Model
400} // namespace EC2
401} // namespace Aws
CopyImageRequest & WithDryRun(bool value)
const Aws::String & GetKmsKeyId() const
CopyImageRequest & AddTagSpecifications(TagSpecificationsT &&value)
CopyImageRequest & WithEncrypted(bool value)
CopyImageRequest & WithName(NameT &&value)
const Aws::String & GetDestinationAvailabilityZone() const
AWS_EC2_API CopyImageRequest()=default
CopyImageRequest & WithKmsKeyId(KmsKeyIdT &&value)
CopyImageRequest & WithSourceRegion(SourceRegionT &&value)
CopyImageRequest & WithClientToken(ClientTokenT &&value)
void SetDescription(DescriptionT &&value)
CopyImageRequest & WithCopyImageTags(bool value)
const Aws::Vector< TagSpecification > & GetTagSpecifications() const
const Aws::String & GetSourceRegion() const
virtual const char * GetServiceRequestName() const override
CopyImageRequest & WithSourceImageId(SourceImageIdT &&value)
void SetDestinationOutpostArn(DestinationOutpostArnT &&value)
void SetDestinationAvailabilityZoneId(DestinationAvailabilityZoneIdT &&value)
const Aws::String & GetClientToken() const
CopyImageRequest & WithTagSpecifications(TagSpecificationsT &&value)
CopyImageRequest & WithDescription(DescriptionT &&value)
const Aws::String & GetSourceImageId() const
void SetTagSpecifications(TagSpecificationsT &&value)
void SetSourceImageId(SourceImageIdT &&value)
AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI &uri) const override
void SetSourceRegion(SourceRegionT &&value)
void SetKmsKeyId(KmsKeyIdT &&value)
long long GetSnapshotCopyCompletionDurationMinutes() const
void SetClientToken(ClientTokenT &&value)
const Aws::String & GetDestinationAvailabilityZoneId() const
const Aws::String & GetDescription() const
void SetDestinationAvailabilityZone(DestinationAvailabilityZoneT &&value)
void SetSnapshotCopyCompletionDurationMinutes(long long value)
CopyImageRequest & WithDestinationOutpostArn(DestinationOutpostArnT &&value)
bool SnapshotCopyCompletionDurationMinutesHasBeenSet() const
CopyImageRequest & WithDestinationAvailabilityZoneId(DestinationAvailabilityZoneIdT &&value)
const Aws::String & GetName() const
const Aws::String & GetDestinationOutpostArn() const
CopyImageRequest & WithDestinationAvailabilityZone(DestinationAvailabilityZoneT &&value)
AWS_EC2_API Aws::String SerializePayload() const override
CopyImageRequest & WithSnapshotCopyCompletionDurationMinutes(long long value)
static Aws::Utils::UUID PseudoRandomUUID()
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector