AWS SDK for C++  1.9.69
AWS SDK for C++
CreateSnapshotRequest.h
Go to the documentation of this file.
1 
6 #pragma once
7 #include <aws/ec2/EC2_EXPORTS.h>
8 #include <aws/ec2/EC2Request.h>
12 #include <utility>
13 
14 namespace Aws
15 {
16 namespace EC2
17 {
18 namespace Model
19 {
20 
24  {
25  public:
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 "CreateSnapshot"; }
33 
34  Aws::String SerializePayload() const override;
35 
36  protected:
37  void DumpBodyToUrl(Aws::Http::URI& uri ) const override;
38 
39  public:
40 
44  inline const Aws::String& GetDescription() const{ return m_description; }
45 
49  inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
50 
54  inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; }
55 
59  inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); }
60 
64  inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); }
65 
69  inline CreateSnapshotRequest& WithDescription(const Aws::String& value) { SetDescription(value); return *this;}
70 
74  inline CreateSnapshotRequest& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;}
75 
79  inline CreateSnapshotRequest& WithDescription(const char* value) { SetDescription(value); return *this;}
80 
81 
96  inline const Aws::String& GetOutpostArn() const{ return m_outpostArn; }
97 
112  inline bool OutpostArnHasBeenSet() const { return m_outpostArnHasBeenSet; }
113 
128  inline void SetOutpostArn(const Aws::String& value) { m_outpostArnHasBeenSet = true; m_outpostArn = value; }
129 
144  inline void SetOutpostArn(Aws::String&& value) { m_outpostArnHasBeenSet = true; m_outpostArn = std::move(value); }
145 
160  inline void SetOutpostArn(const char* value) { m_outpostArnHasBeenSet = true; m_outpostArn.assign(value); }
161 
176  inline CreateSnapshotRequest& WithOutpostArn(const Aws::String& value) { SetOutpostArn(value); return *this;}
177 
192  inline CreateSnapshotRequest& WithOutpostArn(Aws::String&& value) { SetOutpostArn(std::move(value)); return *this;}
193 
208  inline CreateSnapshotRequest& WithOutpostArn(const char* value) { SetOutpostArn(value); return *this;}
209 
210 
214  inline const Aws::String& GetVolumeId() const{ return m_volumeId; }
215 
219  inline bool VolumeIdHasBeenSet() const { return m_volumeIdHasBeenSet; }
220 
224  inline void SetVolumeId(const Aws::String& value) { m_volumeIdHasBeenSet = true; m_volumeId = value; }
225 
229  inline void SetVolumeId(Aws::String&& value) { m_volumeIdHasBeenSet = true; m_volumeId = std::move(value); }
230 
234  inline void SetVolumeId(const char* value) { m_volumeIdHasBeenSet = true; m_volumeId.assign(value); }
235 
239  inline CreateSnapshotRequest& WithVolumeId(const Aws::String& value) { SetVolumeId(value); return *this;}
240 
244  inline CreateSnapshotRequest& WithVolumeId(Aws::String&& value) { SetVolumeId(std::move(value)); return *this;}
245 
249  inline CreateSnapshotRequest& WithVolumeId(const char* value) { SetVolumeId(value); return *this;}
250 
251 
255  inline const Aws::Vector<TagSpecification>& GetTagSpecifications() const{ return m_tagSpecifications; }
256 
260  inline bool TagSpecificationsHasBeenSet() const { return m_tagSpecificationsHasBeenSet; }
261 
265  inline void SetTagSpecifications(const Aws::Vector<TagSpecification>& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications = value; }
266 
270  inline void SetTagSpecifications(Aws::Vector<TagSpecification>&& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications = std::move(value); }
271 
275  inline CreateSnapshotRequest& WithTagSpecifications(const Aws::Vector<TagSpecification>& value) { SetTagSpecifications(value); return *this;}
276 
280  inline CreateSnapshotRequest& WithTagSpecifications(Aws::Vector<TagSpecification>&& value) { SetTagSpecifications(std::move(value)); return *this;}
281 
285  inline CreateSnapshotRequest& AddTagSpecifications(const TagSpecification& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications.push_back(value); return *this; }
286 
290  inline CreateSnapshotRequest& AddTagSpecifications(TagSpecification&& value) { m_tagSpecificationsHasBeenSet = true; m_tagSpecifications.push_back(std::move(value)); return *this; }
291 
292 
299  inline bool GetDryRun() const{ return m_dryRun; }
300 
307  inline bool DryRunHasBeenSet() const { return m_dryRunHasBeenSet; }
308 
315  inline void SetDryRun(bool value) { m_dryRunHasBeenSet = true; m_dryRun = value; }
316 
323  inline CreateSnapshotRequest& WithDryRun(bool value) { SetDryRun(value); return *this;}
324 
325  private:
326 
327  Aws::String m_description;
328  bool m_descriptionHasBeenSet;
329 
330  Aws::String m_outpostArn;
331  bool m_outpostArnHasBeenSet;
332 
333  Aws::String m_volumeId;
334  bool m_volumeIdHasBeenSet;
335 
336  Aws::Vector<TagSpecification> m_tagSpecifications;
337  bool m_tagSpecificationsHasBeenSet;
338 
339  bool m_dryRun;
340  bool m_dryRunHasBeenSet;
341  };
342 
343 } // namespace Model
344 } // namespace EC2
345 } // namespace Aws
TagSpecification.h
Aws::EC2::Model::CreateSnapshotRequest::GetDryRun
bool GetDryRun() const
Definition: CreateSnapshotRequest.h:299
Aws::EC2::Model::CreateSnapshotRequest::WithVolumeId
CreateSnapshotRequest & WithVolumeId(const char *value)
Definition: CreateSnapshotRequest.h:249
Aws::Http::URI
Definition: URI.h:32
Aws::EC2::Model::CreateSnapshotRequest::AddTagSpecifications
CreateSnapshotRequest & AddTagSpecifications(const TagSpecification &value)
Definition: CreateSnapshotRequest.h:285
Aws::EC2::Model::CreateSnapshotRequest::SetDryRun
void SetDryRun(bool value)
Definition: CreateSnapshotRequest.h:315
Aws::EC2::Model::CreateSnapshotRequest::AddTagSpecifications
CreateSnapshotRequest & AddTagSpecifications(TagSpecification &&value)
Definition: CreateSnapshotRequest.h:290
Aws::EC2::Model::CreateSnapshotRequest
Definition: CreateSnapshotRequest.h:24
Aws::EC2::Model::CreateSnapshotRequest::SetVolumeId
void SetVolumeId(const Aws::String &value)
Definition: CreateSnapshotRequest.h:224
AWS_EC2_API
#define AWS_EC2_API
Definition: EC2_EXPORTS.h:28
Aws::EC2::Model::CreateSnapshotRequest::GetDescription
const Aws::String & GetDescription() const
Definition: CreateSnapshotRequest.h:44
Aws::EC2::Model::CreateSnapshotRequest::WithOutpostArn
CreateSnapshotRequest & WithOutpostArn(const Aws::String &value)
Definition: CreateSnapshotRequest.h:176
Aws::EC2::Model::CreateSnapshotRequest::WithDescription
CreateSnapshotRequest & WithDescription(const Aws::String &value)
Definition: CreateSnapshotRequest.h:69
Aws::EC2::Model::CreateSnapshotRequest::WithDescription
CreateSnapshotRequest & WithDescription(Aws::String &&value)
Definition: CreateSnapshotRequest.h:74
Aws::Vector
std::vector< T, Aws::Allocator< T > > Vector
Definition: AWSVector.h:17
Aws::EC2::Model::CreateSnapshotRequest::OutpostArnHasBeenSet
bool OutpostArnHasBeenSet() const
Definition: CreateSnapshotRequest.h:112
Aws::EC2::Model::CreateSnapshotRequest::WithOutpostArn
CreateSnapshotRequest & WithOutpostArn(const char *value)
Definition: CreateSnapshotRequest.h:208
AWSVector.h
Aws::EC2::Model::CreateSnapshotRequest::SetOutpostArn
void SetOutpostArn(const char *value)
Definition: CreateSnapshotRequest.h:160
Aws::EC2::Model::CreateSnapshotRequest::WithDescription
CreateSnapshotRequest & WithDescription(const char *value)
Definition: CreateSnapshotRequest.h:79
Aws::EC2::Model::CreateSnapshotRequest::SetDescription
void SetDescription(const char *value)
Definition: CreateSnapshotRequest.h:64
Aws::EC2::Model::CreateSnapshotRequest::SetVolumeId
void SetVolumeId(Aws::String &&value)
Definition: CreateSnapshotRequest.h:229
Aws::EC2::Model::CreateSnapshotRequest::WithVolumeId
CreateSnapshotRequest & WithVolumeId(const Aws::String &value)
Definition: CreateSnapshotRequest.h:239
Aws::EC2::Model::CreateSnapshotRequest::DryRunHasBeenSet
bool DryRunHasBeenSet() const
Definition: CreateSnapshotRequest.h:307
Aws::EC2::Model::CreateSnapshotRequest::CreateSnapshotRequest
CreateSnapshotRequest()
Aws::EC2::Model::CreateSnapshotRequest::SetOutpostArn
void SetOutpostArn(Aws::String &&value)
Definition: CreateSnapshotRequest.h:144
EC2Request.h
Aws::EC2::Model::CreateSnapshotRequest::GetServiceRequestName
virtual const char * GetServiceRequestName() const override
Definition: CreateSnapshotRequest.h:32
Aws::EC2::Model::CreateSnapshotRequest::GetVolumeId
const Aws::String & GetVolumeId() const
Definition: CreateSnapshotRequest.h:214
Aws::EC2::Model::CreateSnapshotRequest::WithVolumeId
CreateSnapshotRequest & WithVolumeId(Aws::String &&value)
Definition: CreateSnapshotRequest.h:244
Aws::EC2::Model::CreateSnapshotRequest::TagSpecificationsHasBeenSet
bool TagSpecificationsHasBeenSet() const
Definition: CreateSnapshotRequest.h:260
Aws::EC2::Model::CreateSnapshotRequest::SetDescription
void SetDescription(Aws::String &&value)
Definition: CreateSnapshotRequest.h:59
Aws::EC2::Model::CreateSnapshotRequest::WithTagSpecifications
CreateSnapshotRequest & WithTagSpecifications(Aws::Vector< TagSpecification > &&value)
Definition: CreateSnapshotRequest.h:280
AWSString.h
Aws::EC2::Model::CreateSnapshotRequest::WithDryRun
CreateSnapshotRequest & WithDryRun(bool value)
Definition: CreateSnapshotRequest.h:323
Aws::EC2::Model::CreateSnapshotRequest::GetOutpostArn
const Aws::String & GetOutpostArn() const
Definition: CreateSnapshotRequest.h:96
Aws::EC2::Model::CreateSnapshotRequest::WithTagSpecifications
CreateSnapshotRequest & WithTagSpecifications(const Aws::Vector< TagSpecification > &value)
Definition: CreateSnapshotRequest.h:275
Aws::EC2::Model::CreateSnapshotRequest::SetDescription
void SetDescription(const Aws::String &value)
Definition: CreateSnapshotRequest.h:54
Aws
Definition: AccessManagementClient.h:15
Aws::EC2::Model::CreateSnapshotRequest::SetTagSpecifications
void SetTagSpecifications(Aws::Vector< TagSpecification > &&value)
Definition: CreateSnapshotRequest.h:270
Aws::EC2::Model::CreateSnapshotRequest::VolumeIdHasBeenSet
bool VolumeIdHasBeenSet() const
Definition: CreateSnapshotRequest.h:219
Aws::String
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
Aws::EC2::EC2Request
Definition: EC2Request.h:17
Aws::EC2::Model::CreateSnapshotRequest::GetTagSpecifications
const Aws::Vector< TagSpecification > & GetTagSpecifications() const
Definition: CreateSnapshotRequest.h:255
Aws::EC2::Model::CreateSnapshotRequest::DumpBodyToUrl
void DumpBodyToUrl(Aws::Http::URI &uri) const override
Aws::EC2::Model::CreateSnapshotRequest::SetTagSpecifications
void SetTagSpecifications(const Aws::Vector< TagSpecification > &value)
Definition: CreateSnapshotRequest.h:265
Aws::EC2::Model::CreateSnapshotRequest::SetVolumeId
void SetVolumeId(const char *value)
Definition: CreateSnapshotRequest.h:234
Aws::EC2::Model::TagSpecification
Definition: TagSpecification.h:35
EC2_EXPORTS.h
Aws::EC2::Model::CreateSnapshotRequest::SetOutpostArn
void SetOutpostArn(const Aws::String &value)
Definition: CreateSnapshotRequest.h:128
Aws::EC2::Model::CreateSnapshotRequest::WithOutpostArn
CreateSnapshotRequest & WithOutpostArn(Aws::String &&value)
Definition: CreateSnapshotRequest.h:192
Aws::EC2::Model::CreateSnapshotRequest::DescriptionHasBeenSet
bool DescriptionHasBeenSet() const
Definition: CreateSnapshotRequest.h:49
Aws::EC2::Model::CreateSnapshotRequest::SerializePayload
Aws::String SerializePayload() const override