AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
ExportImageRequest.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/DiskImageFormat.h>
13#include <aws/ec2/model/ExportTaskS3LocationRequest.h>
14#include <aws/ec2/model/TagSpecification.h>
15
16#include <utility>
17
18namespace Aws {
19namespace EC2 {
20namespace Model {
21
25 public:
26 AWS_EC2_API ExportImageRequest() = default;
27
28 // Service request name is the Operation name which will send this request out,
29 // each operation should has unique request name, so that we can get operation's name from this request.
30 // Note: this is not true for response, multiple operations may have the same response name,
31 // so we can not get operation's name from response.
32 inline virtual const char* GetServiceRequestName() const override { return "ExportImage"; }
33
34 AWS_EC2_API Aws::String SerializePayload() const override;
35
36 protected:
37 AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI& uri) const override;
38
39 public:
41
44 inline const Aws::String& GetClientToken() const { return m_clientToken; }
45 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
46 template <typename ClientTokenT = Aws::String>
47 void SetClientToken(ClientTokenT&& value) {
48 m_clientTokenHasBeenSet = true;
49 m_clientToken = std::forward<ClientTokenT>(value);
50 }
51 template <typename ClientTokenT = Aws::String>
52 ExportImageRequest& WithClientToken(ClientTokenT&& value) {
53 SetClientToken(std::forward<ClientTokenT>(value));
54 return *this;
55 }
57
59
63 inline const Aws::String& GetDescription() const { return m_description; }
64 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
65 template <typename DescriptionT = Aws::String>
66 void SetDescription(DescriptionT&& value) {
67 m_descriptionHasBeenSet = true;
68 m_description = std::forward<DescriptionT>(value);
69 }
70 template <typename DescriptionT = Aws::String>
71 ExportImageRequest& WithDescription(DescriptionT&& value) {
72 SetDescription(std::forward<DescriptionT>(value));
73 return *this;
74 }
76
78
81 inline DiskImageFormat GetDiskImageFormat() const { return m_diskImageFormat; }
82 inline bool DiskImageFormatHasBeenSet() const { return m_diskImageFormatHasBeenSet; }
84 m_diskImageFormatHasBeenSet = true;
85 m_diskImageFormat = value;
86 }
88 SetDiskImageFormat(value);
89 return *this;
90 }
92
94
100 inline bool GetDryRun() const { return m_dryRun; }
101 inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; }
102 inline void SetDryRun(bool value) {
103 m_dryRunHasBeenSet = true;
104 m_dryRun = value;
105 }
106 inline ExportImageRequest& WithDryRun(bool value) {
107 SetDryRun(value);
108 return *this;
109 }
111
113
116 inline const Aws::String& GetImageId() const { return m_imageId; }
117 inline bool ImageIdHasBeenSet() const { return m_imageIdHasBeenSet; }
118 template <typename ImageIdT = Aws::String>
119 void SetImageId(ImageIdT&& value) {
120 m_imageIdHasBeenSet = true;
121 m_imageId = std::forward<ImageIdT>(value);
122 }
123 template <typename ImageIdT = Aws::String>
124 ExportImageRequest& WithImageId(ImageIdT&& value) {
125 SetImageId(std::forward<ImageIdT>(value));
126 return *this;
127 }
129
131
135 inline const ExportTaskS3LocationRequest& GetS3ExportLocation() const { return m_s3ExportLocation; }
136 inline bool S3ExportLocationHasBeenSet() const { return m_s3ExportLocationHasBeenSet; }
137 template <typename S3ExportLocationT = ExportTaskS3LocationRequest>
138 void SetS3ExportLocation(S3ExportLocationT&& value) {
139 m_s3ExportLocationHasBeenSet = true;
140 m_s3ExportLocation = std::forward<S3ExportLocationT>(value);
141 }
142 template <typename S3ExportLocationT = ExportTaskS3LocationRequest>
143 ExportImageRequest& WithS3ExportLocation(S3ExportLocationT&& value) {
144 SetS3ExportLocation(std::forward<S3ExportLocationT>(value));
145 return *this;
146 }
148
150
155 inline const Aws::String& GetRoleName() const { return m_roleName; }
156 inline bool RoleNameHasBeenSet() const { return m_roleNameHasBeenSet; }
157 template <typename RoleNameT = Aws::String>
158 void SetRoleName(RoleNameT&& value) {
159 m_roleNameHasBeenSet = true;
160 m_roleName = std::forward<RoleNameT>(value);
161 }
162 template <typename RoleNameT = Aws::String>
163 ExportImageRequest& WithRoleName(RoleNameT&& value) {
164 SetRoleName(std::forward<RoleNameT>(value));
165 return *this;
166 }
168
170
173 inline const Aws::Vector<TagSpecification>& GetTagSpecifications() const { return m_tagSpecifications; }
174 inline bool TagSpecificationsHasBeenSet() const { return m_tagSpecificationsHasBeenSet; }
175 template <typename TagSpecificationsT = Aws::Vector<TagSpecification>>
176 void SetTagSpecifications(TagSpecificationsT&& value) {
177 m_tagSpecificationsHasBeenSet = true;
178 m_tagSpecifications = std::forward<TagSpecificationsT>(value);
179 }
180 template <typename TagSpecificationsT = Aws::Vector<TagSpecification>>
181 ExportImageRequest& WithTagSpecifications(TagSpecificationsT&& value) {
182 SetTagSpecifications(std::forward<TagSpecificationsT>(value));
183 return *this;
184 }
185 template <typename TagSpecificationsT = TagSpecification>
186 ExportImageRequest& AddTagSpecifications(TagSpecificationsT&& value) {
187 m_tagSpecificationsHasBeenSet = true;
188 m_tagSpecifications.emplace_back(std::forward<TagSpecificationsT>(value));
189 return *this;
190 }
192 private:
194
195 Aws::String m_description;
196
197 DiskImageFormat m_diskImageFormat{DiskImageFormat::NOT_SET};
198
199 bool m_dryRun{false};
200
201 Aws::String m_imageId;
202
203 ExportTaskS3LocationRequest m_s3ExportLocation;
204
205 Aws::String m_roleName;
206
207 Aws::Vector<TagSpecification> m_tagSpecifications;
208 bool m_clientTokenHasBeenSet = true;
209 bool m_descriptionHasBeenSet = false;
210 bool m_diskImageFormatHasBeenSet = false;
211 bool m_dryRunHasBeenSet = false;
212 bool m_imageIdHasBeenSet = false;
213 bool m_s3ExportLocationHasBeenSet = false;
214 bool m_roleNameHasBeenSet = false;
215 bool m_tagSpecificationsHasBeenSet = false;
216};
217
218} // namespace Model
219} // namespace EC2
220} // namespace Aws
ExportImageRequest & WithDryRun(bool value)
ExportImageRequest & WithDescription(DescriptionT &&value)
void SetClientToken(ClientTokenT &&value)
ExportImageRequest & WithRoleName(RoleNameT &&value)
ExportImageRequest & WithS3ExportLocation(S3ExportLocationT &&value)
const Aws::String & GetRoleName() const
void SetS3ExportLocation(S3ExportLocationT &&value)
ExportImageRequest & WithImageId(ImageIdT &&value)
ExportImageRequest & WithClientToken(ClientTokenT &&value)
const Aws::String & GetClientToken() const
ExportImageRequest & WithTagSpecifications(TagSpecificationsT &&value)
const Aws::Vector< TagSpecification > & GetTagSpecifications() const
ExportImageRequest & AddTagSpecifications(TagSpecificationsT &&value)
ExportImageRequest & WithDiskImageFormat(DiskImageFormat value)
virtual const char * GetServiceRequestName() const override
const Aws::String & GetDescription() const
AWS_EC2_API Aws::String SerializePayload() const override
AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI &uri) const override
DiskImageFormat GetDiskImageFormat() const
void SetDescription(DescriptionT &&value)
void SetTagSpecifications(TagSpecificationsT &&value)
const Aws::String & GetImageId() const
const ExportTaskS3LocationRequest & GetS3ExportLocation() const
void SetDiskImageFormat(DiskImageFormat value)
AWS_EC2_API ExportImageRequest()=default
static Aws::Utils::UUID PseudoRandomUUID()
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector