AWS SDK for C++

AWS SDK for C++ Version 1.11.717

Loading...
Searching...
No Matches
ImportImageRequest.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/ec2/EC2Request.h>
10#include <aws/ec2/EC2_EXPORTS.h>
11#include <aws/ec2/model/BootModeValues.h>
12#include <aws/ec2/model/ClientData.h>
13#include <aws/ec2/model/ImageDiskContainer.h>
14#include <aws/ec2/model/ImportImageLicenseConfigurationRequest.h>
15#include <aws/ec2/model/TagSpecification.h>
16
17#include <utility>
18
19namespace Aws {
20namespace EC2 {
21namespace Model {
22
26 public:
27 AWS_EC2_API ImportImageRequest() = 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 "ImportImage"; }
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
46 inline const Aws::String& GetArchitecture() const { return m_architecture; }
47 inline bool ArchitectureHasBeenSet() const { return m_architectureHasBeenSet; }
48 template <typename ArchitectureT = Aws::String>
49 void SetArchitecture(ArchitectureT&& value) {
50 m_architectureHasBeenSet = true;
51 m_architecture = std::forward<ArchitectureT>(value);
52 }
53 template <typename ArchitectureT = Aws::String>
54 ImportImageRequest& WithArchitecture(ArchitectureT&& value) {
55 SetArchitecture(std::forward<ArchitectureT>(value));
56 return *this;
57 }
59
61
64 inline const ClientData& GetClientData() const { return m_clientData; }
65 inline bool ClientDataHasBeenSet() const { return m_clientDataHasBeenSet; }
66 template <typename ClientDataT = ClientData>
67 void SetClientData(ClientDataT&& value) {
68 m_clientDataHasBeenSet = true;
69 m_clientData = std::forward<ClientDataT>(value);
70 }
71 template <typename ClientDataT = ClientData>
72 ImportImageRequest& WithClientData(ClientDataT&& value) {
73 SetClientData(std::forward<ClientDataT>(value));
74 return *this;
75 }
77
79
82 inline const Aws::String& GetClientToken() const { return m_clientToken; }
83 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
84 template <typename ClientTokenT = Aws::String>
85 void SetClientToken(ClientTokenT&& value) {
86 m_clientTokenHasBeenSet = true;
87 m_clientToken = std::forward<ClientTokenT>(value);
88 }
89 template <typename ClientTokenT = Aws::String>
90 ImportImageRequest& WithClientToken(ClientTokenT&& value) {
91 SetClientToken(std::forward<ClientTokenT>(value));
92 return *this;
93 }
95
97
100 inline const Aws::String& GetDescription() const { return m_description; }
101 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
102 template <typename DescriptionT = Aws::String>
103 void SetDescription(DescriptionT&& value) {
104 m_descriptionHasBeenSet = true;
105 m_description = std::forward<DescriptionT>(value);
106 }
107 template <typename DescriptionT = Aws::String>
108 ImportImageRequest& WithDescription(DescriptionT&& value) {
109 SetDescription(std::forward<DescriptionT>(value));
110 return *this;
111 }
113
115
118 inline const Aws::Vector<ImageDiskContainer>& GetDiskContainers() const { return m_diskContainers; }
119 inline bool DiskContainersHasBeenSet() const { return m_diskContainersHasBeenSet; }
120 template <typename DiskContainersT = Aws::Vector<ImageDiskContainer>>
121 void SetDiskContainers(DiskContainersT&& value) {
122 m_diskContainersHasBeenSet = true;
123 m_diskContainers = std::forward<DiskContainersT>(value);
124 }
125 template <typename DiskContainersT = Aws::Vector<ImageDiskContainer>>
126 ImportImageRequest& WithDiskContainers(DiskContainersT&& value) {
127 SetDiskContainers(std::forward<DiskContainersT>(value));
128 return *this;
129 }
130 template <typename DiskContainersT = ImageDiskContainer>
131 ImportImageRequest& AddDiskContainers(DiskContainersT&& value) {
132 m_diskContainersHasBeenSet = true;
133 m_diskContainers.emplace_back(std::forward<DiskContainersT>(value));
134 return *this;
135 }
137
139
145 inline bool GetDryRun() const { return m_dryRun; }
146 inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; }
147 inline void SetDryRun(bool value) {
148 m_dryRunHasBeenSet = true;
149 m_dryRun = value;
150 }
151 inline ImportImageRequest& WithDryRun(bool value) {
152 SetDryRun(value);
153 return *this;
154 }
156
158
165 inline bool GetEncrypted() const { return m_encrypted; }
166 inline bool EncryptedHasBeenSet() const { return m_encryptedHasBeenSet; }
167 inline void SetEncrypted(bool value) {
168 m_encryptedHasBeenSet = true;
169 m_encrypted = value;
170 }
171 inline ImportImageRequest& WithEncrypted(bool value) {
172 SetEncrypted(value);
173 return *this;
174 }
176
178
181 inline const Aws::String& GetHypervisor() const { return m_hypervisor; }
182 inline bool HypervisorHasBeenSet() const { return m_hypervisorHasBeenSet; }
183 template <typename HypervisorT = Aws::String>
184 void SetHypervisor(HypervisorT&& value) {
185 m_hypervisorHasBeenSet = true;
186 m_hypervisor = std::forward<HypervisorT>(value);
187 }
188 template <typename HypervisorT = Aws::String>
189 ImportImageRequest& WithHypervisor(HypervisorT&& value) {
190 SetHypervisor(std::forward<HypervisorT>(value));
191 return *this;
192 }
194
196
218 inline const Aws::String& GetKmsKeyId() const { return m_kmsKeyId; }
219 inline bool KmsKeyIdHasBeenSet() const { return m_kmsKeyIdHasBeenSet; }
220 template <typename KmsKeyIdT = Aws::String>
221 void SetKmsKeyId(KmsKeyIdT&& value) {
222 m_kmsKeyIdHasBeenSet = true;
223 m_kmsKeyId = std::forward<KmsKeyIdT>(value);
224 }
225 template <typename KmsKeyIdT = Aws::String>
226 ImportImageRequest& WithKmsKeyId(KmsKeyIdT&& value) {
227 SetKmsKeyId(std::forward<KmsKeyIdT>(value));
228 return *this;
229 }
231
233
247 inline const Aws::String& GetLicenseType() const { return m_licenseType; }
248 inline bool LicenseTypeHasBeenSet() const { return m_licenseTypeHasBeenSet; }
249 template <typename LicenseTypeT = Aws::String>
250 void SetLicenseType(LicenseTypeT&& value) {
251 m_licenseTypeHasBeenSet = true;
252 m_licenseType = std::forward<LicenseTypeT>(value);
253 }
254 template <typename LicenseTypeT = Aws::String>
255 ImportImageRequest& WithLicenseType(LicenseTypeT&& value) {
256 SetLicenseType(std::forward<LicenseTypeT>(value));
257 return *this;
258 }
260
262
268 inline const Aws::String& GetPlatform() const { return m_platform; }
269 inline bool PlatformHasBeenSet() const { return m_platformHasBeenSet; }
270 template <typename PlatformT = Aws::String>
271 void SetPlatform(PlatformT&& value) {
272 m_platformHasBeenSet = true;
273 m_platform = std::forward<PlatformT>(value);
274 }
275 template <typename PlatformT = Aws::String>
276 ImportImageRequest& WithPlatform(PlatformT&& value) {
277 SetPlatform(std::forward<PlatformT>(value));
278 return *this;
279 }
281
283
286 inline const Aws::String& GetRoleName() const { return m_roleName; }
287 inline bool RoleNameHasBeenSet() const { return m_roleNameHasBeenSet; }
288 template <typename RoleNameT = Aws::String>
289 void SetRoleName(RoleNameT&& value) {
290 m_roleNameHasBeenSet = true;
291 m_roleName = std::forward<RoleNameT>(value);
292 }
293 template <typename RoleNameT = Aws::String>
294 ImportImageRequest& WithRoleName(RoleNameT&& value) {
295 SetRoleName(std::forward<RoleNameT>(value));
296 return *this;
297 }
299
301
304 inline const Aws::Vector<ImportImageLicenseConfigurationRequest>& GetLicenseSpecifications() const { return m_licenseSpecifications; }
305 inline bool LicenseSpecificationsHasBeenSet() const { return m_licenseSpecificationsHasBeenSet; }
306 template <typename LicenseSpecificationsT = Aws::Vector<ImportImageLicenseConfigurationRequest>>
307 void SetLicenseSpecifications(LicenseSpecificationsT&& value) {
308 m_licenseSpecificationsHasBeenSet = true;
309 m_licenseSpecifications = std::forward<LicenseSpecificationsT>(value);
310 }
311 template <typename LicenseSpecificationsT = Aws::Vector<ImportImageLicenseConfigurationRequest>>
312 ImportImageRequest& WithLicenseSpecifications(LicenseSpecificationsT&& value) {
313 SetLicenseSpecifications(std::forward<LicenseSpecificationsT>(value));
314 return *this;
315 }
316 template <typename LicenseSpecificationsT = ImportImageLicenseConfigurationRequest>
317 ImportImageRequest& AddLicenseSpecifications(LicenseSpecificationsT&& value) {
318 m_licenseSpecificationsHasBeenSet = true;
319 m_licenseSpecifications.emplace_back(std::forward<LicenseSpecificationsT>(value));
320 return *this;
321 }
323
325
328 inline const Aws::Vector<TagSpecification>& GetTagSpecifications() const { return m_tagSpecifications; }
329 inline bool TagSpecificationsHasBeenSet() const { return m_tagSpecificationsHasBeenSet; }
330 template <typename TagSpecificationsT = Aws::Vector<TagSpecification>>
331 void SetTagSpecifications(TagSpecificationsT&& value) {
332 m_tagSpecificationsHasBeenSet = true;
333 m_tagSpecifications = std::forward<TagSpecificationsT>(value);
334 }
335 template <typename TagSpecificationsT = Aws::Vector<TagSpecification>>
336 ImportImageRequest& WithTagSpecifications(TagSpecificationsT&& value) {
337 SetTagSpecifications(std::forward<TagSpecificationsT>(value));
338 return *this;
339 }
340 template <typename TagSpecificationsT = TagSpecification>
341 ImportImageRequest& AddTagSpecifications(TagSpecificationsT&& value) {
342 m_tagSpecificationsHasBeenSet = true;
343 m_tagSpecifications.emplace_back(std::forward<TagSpecificationsT>(value));
344 return *this;
345 }
347
349
354 inline const Aws::String& GetUsageOperation() const { return m_usageOperation; }
355 inline bool UsageOperationHasBeenSet() const { return m_usageOperationHasBeenSet; }
356 template <typename UsageOperationT = Aws::String>
357 void SetUsageOperation(UsageOperationT&& value) {
358 m_usageOperationHasBeenSet = true;
359 m_usageOperation = std::forward<UsageOperationT>(value);
360 }
361 template <typename UsageOperationT = Aws::String>
362 ImportImageRequest& WithUsageOperation(UsageOperationT&& value) {
363 SetUsageOperation(std::forward<UsageOperationT>(value));
364 return *this;
365 }
367
369
376 inline BootModeValues GetBootMode() const { return m_bootMode; }
377 inline bool BootModeHasBeenSet() const { return m_bootModeHasBeenSet; }
378 inline void SetBootMode(BootModeValues value) {
379 m_bootModeHasBeenSet = true;
380 m_bootMode = value;
381 }
383 SetBootMode(value);
384 return *this;
385 }
387 private:
388 Aws::String m_architecture;
389
390 ClientData m_clientData;
391
392 Aws::String m_clientToken;
393
394 Aws::String m_description;
395
396 Aws::Vector<ImageDiskContainer> m_diskContainers;
397
398 bool m_dryRun{false};
399
400 bool m_encrypted{false};
401
402 Aws::String m_hypervisor;
403
404 Aws::String m_kmsKeyId;
405
406 Aws::String m_licenseType;
407
408 Aws::String m_platform;
409
410 Aws::String m_roleName;
411
413
414 Aws::Vector<TagSpecification> m_tagSpecifications;
415
416 Aws::String m_usageOperation;
417
419 bool m_architectureHasBeenSet = false;
420 bool m_clientDataHasBeenSet = false;
421 bool m_clientTokenHasBeenSet = false;
422 bool m_descriptionHasBeenSet = false;
423 bool m_diskContainersHasBeenSet = false;
424 bool m_dryRunHasBeenSet = false;
425 bool m_encryptedHasBeenSet = false;
426 bool m_hypervisorHasBeenSet = false;
427 bool m_kmsKeyIdHasBeenSet = false;
428 bool m_licenseTypeHasBeenSet = false;
429 bool m_platformHasBeenSet = false;
430 bool m_roleNameHasBeenSet = false;
431 bool m_licenseSpecificationsHasBeenSet = false;
432 bool m_tagSpecificationsHasBeenSet = false;
433 bool m_usageOperationHasBeenSet = false;
434 bool m_bootModeHasBeenSet = false;
435};
436
437} // namespace Model
438} // namespace EC2
439} // namespace Aws
ImportImageRequest & WithTagSpecifications(TagSpecificationsT &&value)
const Aws::String & GetUsageOperation() const
void SetTagSpecifications(TagSpecificationsT &&value)
void SetDiskContainers(DiskContainersT &&value)
const Aws::String & GetPlatform() const
const Aws::String & GetLicenseType() const
ImportImageRequest & WithDescription(DescriptionT &&value)
ImportImageRequest & WithBootMode(BootModeValues value)
AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI &uri) const override
ImportImageRequest & WithUsageOperation(UsageOperationT &&value)
void SetArchitecture(ArchitectureT &&value)
void SetBootMode(BootModeValues value)
const Aws::String & GetKmsKeyId() const
void SetHypervisor(HypervisorT &&value)
const Aws::String & GetRoleName() const
void SetClientData(ClientDataT &&value)
void SetUsageOperation(UsageOperationT &&value)
const ClientData & GetClientData() const
const Aws::Vector< ImportImageLicenseConfigurationRequest > & GetLicenseSpecifications() const
const Aws::String & GetHypervisor() const
ImportImageRequest & WithKmsKeyId(KmsKeyIdT &&value)
const Aws::String & GetDescription() const
ImportImageRequest & WithEncrypted(bool value)
ImportImageRequest & AddLicenseSpecifications(LicenseSpecificationsT &&value)
void SetLicenseSpecifications(LicenseSpecificationsT &&value)
ImportImageRequest & WithClientToken(ClientTokenT &&value)
ImportImageRequest & WithClientData(ClientDataT &&value)
ImportImageRequest & WithLicenseType(LicenseTypeT &&value)
void SetClientToken(ClientTokenT &&value)
const Aws::String & GetClientToken() const
ImportImageRequest & AddDiskContainers(DiskContainersT &&value)
const Aws::Vector< ImageDiskContainer > & GetDiskContainers() const
void SetDescription(DescriptionT &&value)
ImportImageRequest & WithArchitecture(ArchitectureT &&value)
ImportImageRequest & WithDryRun(bool value)
const Aws::String & GetArchitecture() const
AWS_EC2_API Aws::String SerializePayload() const override
void SetLicenseType(LicenseTypeT &&value)
const Aws::Vector< TagSpecification > & GetTagSpecifications() const
ImportImageRequest & AddTagSpecifications(TagSpecificationsT &&value)
ImportImageRequest & WithDiskContainers(DiskContainersT &&value)
ImportImageRequest & WithRoleName(RoleNameT &&value)
ImportImageRequest & WithLicenseSpecifications(LicenseSpecificationsT &&value)
virtual const char * GetServiceRequestName() const override
ImportImageRequest & WithPlatform(PlatformT &&value)
AWS_EC2_API ImportImageRequest()=default
ImportImageRequest & WithHypervisor(HypervisorT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector