AWS SDK for C++

AWS SDK for C++ Version 1.11.788

Loading...
Searching...
No Matches
CreateVolumeRequest.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/workspaces-instances/WorkspacesInstancesRequest.h>
11#include <aws/workspaces-instances/WorkspacesInstances_EXPORTS.h>
12#include <aws/workspaces-instances/model/TagSpecification.h>
13#include <aws/workspaces-instances/model/VolumeTypeEnum.h>
14
15#include <utility>
16
17namespace Aws {
18namespace WorkspacesInstances {
19namespace Model {
20
27 public:
28 AWS_WORKSPACESINSTANCES_API CreateVolumeRequest() = default;
29
30 // Service request name is the Operation name which will send this request out,
31 // each operation should has unique request name, so that we can get operation's name from this request.
32 // Note: this is not true for response, multiple operations may have the same response name,
33 // so we can not get operation's name from response.
34 inline virtual const char* GetServiceRequestName() const override { return "CreateVolume"; }
35
36 AWS_WORKSPACESINSTANCES_API Aws::String SerializePayload() const override;
37
38 AWS_WORKSPACESINSTANCES_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
39
41
44 inline const Aws::String& GetAvailabilityZone() const { return m_availabilityZone; }
45 inline bool AvailabilityZoneHasBeenSet() const { return m_availabilityZoneHasBeenSet; }
46 template <typename AvailabilityZoneT = Aws::String>
47 void SetAvailabilityZone(AvailabilityZoneT&& value) {
48 m_availabilityZoneHasBeenSet = true;
49 m_availabilityZone = std::forward<AvailabilityZoneT>(value);
50 }
51 template <typename AvailabilityZoneT = Aws::String>
52 CreateVolumeRequest& WithAvailabilityZone(AvailabilityZoneT&& value) {
53 SetAvailabilityZone(std::forward<AvailabilityZoneT>(value));
54 return *this;
55 }
57
59
62 inline const Aws::String& GetClientToken() const { return m_clientToken; }
63 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
64 template <typename ClientTokenT = Aws::String>
65 void SetClientToken(ClientTokenT&& value) {
66 m_clientTokenHasBeenSet = true;
67 m_clientToken = std::forward<ClientTokenT>(value);
68 }
69 template <typename ClientTokenT = Aws::String>
70 CreateVolumeRequest& WithClientToken(ClientTokenT&& value) {
71 SetClientToken(std::forward<ClientTokenT>(value));
72 return *this;
73 }
75
77
80 inline bool GetEncrypted() const { return m_encrypted; }
81 inline bool EncryptedHasBeenSet() const { return m_encryptedHasBeenSet; }
82 inline void SetEncrypted(bool value) {
83 m_encryptedHasBeenSet = true;
84 m_encrypted = value;
85 }
86 inline CreateVolumeRequest& WithEncrypted(bool value) {
87 SetEncrypted(value);
88 return *this;
89 }
91
93
96 inline int GetIops() const { return m_iops; }
97 inline bool IopsHasBeenSet() const { return m_iopsHasBeenSet; }
98 inline void SetIops(int value) {
99 m_iopsHasBeenSet = true;
100 m_iops = value;
101 }
102 inline CreateVolumeRequest& WithIops(int value) {
103 SetIops(value);
104 return *this;
105 }
107
109
112 inline const Aws::String& GetKmsKeyId() const { return m_kmsKeyId; }
113 inline bool KmsKeyIdHasBeenSet() const { return m_kmsKeyIdHasBeenSet; }
114 template <typename KmsKeyIdT = Aws::String>
115 void SetKmsKeyId(KmsKeyIdT&& value) {
116 m_kmsKeyIdHasBeenSet = true;
117 m_kmsKeyId = std::forward<KmsKeyIdT>(value);
118 }
119 template <typename KmsKeyIdT = Aws::String>
120 CreateVolumeRequest& WithKmsKeyId(KmsKeyIdT&& value) {
121 SetKmsKeyId(std::forward<KmsKeyIdT>(value));
122 return *this;
123 }
125
127
130 inline int GetSizeInGB() const { return m_sizeInGB; }
131 inline bool SizeInGBHasBeenSet() const { return m_sizeInGBHasBeenSet; }
132 inline void SetSizeInGB(int value) {
133 m_sizeInGBHasBeenSet = true;
134 m_sizeInGB = value;
135 }
137 SetSizeInGB(value);
138 return *this;
139 }
141
143
146 inline const Aws::String& GetSnapshotId() const { return m_snapshotId; }
147 inline bool SnapshotIdHasBeenSet() const { return m_snapshotIdHasBeenSet; }
148 template <typename SnapshotIdT = Aws::String>
149 void SetSnapshotId(SnapshotIdT&& value) {
150 m_snapshotIdHasBeenSet = true;
151 m_snapshotId = std::forward<SnapshotIdT>(value);
152 }
153 template <typename SnapshotIdT = Aws::String>
154 CreateVolumeRequest& WithSnapshotId(SnapshotIdT&& value) {
155 SetSnapshotId(std::forward<SnapshotIdT>(value));
156 return *this;
157 }
159
161
164 inline const Aws::Vector<TagSpecification>& GetTagSpecifications() const { return m_tagSpecifications; }
165 inline bool TagSpecificationsHasBeenSet() const { return m_tagSpecificationsHasBeenSet; }
166 template <typename TagSpecificationsT = Aws::Vector<TagSpecification>>
167 void SetTagSpecifications(TagSpecificationsT&& value) {
168 m_tagSpecificationsHasBeenSet = true;
169 m_tagSpecifications = std::forward<TagSpecificationsT>(value);
170 }
171 template <typename TagSpecificationsT = Aws::Vector<TagSpecification>>
172 CreateVolumeRequest& WithTagSpecifications(TagSpecificationsT&& value) {
173 SetTagSpecifications(std::forward<TagSpecificationsT>(value));
174 return *this;
175 }
176 template <typename TagSpecificationsT = TagSpecification>
177 CreateVolumeRequest& AddTagSpecifications(TagSpecificationsT&& value) {
178 m_tagSpecificationsHasBeenSet = true;
179 m_tagSpecifications.emplace_back(std::forward<TagSpecificationsT>(value));
180 return *this;
181 }
183
185
188 inline int GetThroughput() const { return m_throughput; }
189 inline bool ThroughputHasBeenSet() const { return m_throughputHasBeenSet; }
190 inline void SetThroughput(int value) {
191 m_throughputHasBeenSet = true;
192 m_throughput = value;
193 }
195 SetThroughput(value);
196 return *this;
197 }
199
201
204 inline VolumeTypeEnum GetVolumeType() const { return m_volumeType; }
205 inline bool VolumeTypeHasBeenSet() const { return m_volumeTypeHasBeenSet; }
206 inline void SetVolumeType(VolumeTypeEnum value) {
207 m_volumeTypeHasBeenSet = true;
208 m_volumeType = value;
209 }
211 SetVolumeType(value);
212 return *this;
213 }
215 private:
216 Aws::String m_availabilityZone;
217
219
220 bool m_encrypted{false};
221
222 int m_iops{0};
223
224 Aws::String m_kmsKeyId;
225
226 int m_sizeInGB{0};
227
228 Aws::String m_snapshotId;
229
230 Aws::Vector<TagSpecification> m_tagSpecifications;
231
232 int m_throughput{0};
233
235 bool m_availabilityZoneHasBeenSet = false;
236 bool m_clientTokenHasBeenSet = true;
237 bool m_encryptedHasBeenSet = false;
238 bool m_iopsHasBeenSet = false;
239 bool m_kmsKeyIdHasBeenSet = false;
240 bool m_sizeInGBHasBeenSet = false;
241 bool m_snapshotIdHasBeenSet = false;
242 bool m_tagSpecificationsHasBeenSet = false;
243 bool m_throughputHasBeenSet = false;
244 bool m_volumeTypeHasBeenSet = false;
245};
246
247} // namespace Model
248} // namespace WorkspacesInstances
249} // namespace Aws
static Aws::Utils::UUID PseudoRandomUUID()
virtual const char * GetServiceRequestName() const override
CreateVolumeRequest & WithKmsKeyId(KmsKeyIdT &&value)
AWS_WORKSPACESINSTANCES_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
AWS_WORKSPACESINSTANCES_API CreateVolumeRequest()=default
CreateVolumeRequest & WithClientToken(ClientTokenT &&value)
CreateVolumeRequest & WithSnapshotId(SnapshotIdT &&value)
AWS_WORKSPACESINSTANCES_API Aws::String SerializePayload() const override
CreateVolumeRequest & WithAvailabilityZone(AvailabilityZoneT &&value)
const Aws::Vector< TagSpecification > & GetTagSpecifications() const
CreateVolumeRequest & WithTagSpecifications(TagSpecificationsT &&value)
CreateVolumeRequest & WithVolumeType(VolumeTypeEnum value)
CreateVolumeRequest & AddTagSpecifications(TagSpecificationsT &&value)
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector