AWS SDK for C++

AWS SDK for C++ Version 1.11.607

Loading...
Searching...
No Matches
StartSnapshotRequest.h
1
6#pragma once
7#include <aws/ebs/EBS_EXPORTS.h>
8#include <aws/ebs/EBSRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/ebs/model/Tag.h>
12#include <utility>
13#include <aws/core/utils/UUID.h>
14
15namespace Aws
16{
17namespace EBS
18{
19namespace Model
20{
21
25 {
26 public:
27 AWS_EBS_API StartSnapshotRequest() = 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 "StartSnapshot"; }
34
35 AWS_EBS_API Aws::String SerializePayload() const override;
36
37
39
43 inline long long GetVolumeSize() const { return m_volumeSize; }
44 inline bool VolumeSizeHasBeenSet() const { return m_volumeSizeHasBeenSet; }
45 inline void SetVolumeSize(long long value) { m_volumeSizeHasBeenSet = true; m_volumeSize = value; }
46 inline StartSnapshotRequest& WithVolumeSize(long long value) { SetVolumeSize(value); return *this;}
48
50
70 inline const Aws::String& GetParentSnapshotId() const { return m_parentSnapshotId; }
71 inline bool ParentSnapshotIdHasBeenSet() const { return m_parentSnapshotIdHasBeenSet; }
72 template<typename ParentSnapshotIdT = Aws::String>
73 void SetParentSnapshotId(ParentSnapshotIdT&& value) { m_parentSnapshotIdHasBeenSet = true; m_parentSnapshotId = std::forward<ParentSnapshotIdT>(value); }
74 template<typename ParentSnapshotIdT = Aws::String>
75 StartSnapshotRequest& WithParentSnapshotId(ParentSnapshotIdT&& value) { SetParentSnapshotId(std::forward<ParentSnapshotIdT>(value)); return *this;}
77
79
82 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
83 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
84 template<typename TagsT = Aws::Vector<Tag>>
85 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
86 template<typename TagsT = Aws::Vector<Tag>>
87 StartSnapshotRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
88 template<typename TagsT = Tag>
89 StartSnapshotRequest& AddTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags.emplace_back(std::forward<TagsT>(value)); return *this; }
91
93
96 inline const Aws::String& GetDescription() const { return m_description; }
97 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
98 template<typename DescriptionT = Aws::String>
99 void SetDescription(DescriptionT&& value) { m_descriptionHasBeenSet = true; m_description = std::forward<DescriptionT>(value); }
100 template<typename DescriptionT = Aws::String>
101 StartSnapshotRequest& WithDescription(DescriptionT&& value) { SetDescription(std::forward<DescriptionT>(value)); return *this;}
103
105
117 inline const Aws::String& GetClientToken() const { return m_clientToken; }
118 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
119 template<typename ClientTokenT = Aws::String>
120 void SetClientToken(ClientTokenT&& value) { m_clientTokenHasBeenSet = true; m_clientToken = std::forward<ClientTokenT>(value); }
121 template<typename ClientTokenT = Aws::String>
122 StartSnapshotRequest& WithClientToken(ClientTokenT&& value) { SetClientToken(std::forward<ClientTokenT>(value)); return *this;}
124
126
144 inline bool GetEncrypted() const { return m_encrypted; }
145 inline bool EncryptedHasBeenSet() const { return m_encryptedHasBeenSet; }
146 inline void SetEncrypted(bool value) { m_encryptedHasBeenSet = true; m_encrypted = value; }
147 inline StartSnapshotRequest& WithEncrypted(bool value) { SetEncrypted(value); return *this;}
149
151
167 inline const Aws::String& GetKmsKeyArn() const { return m_kmsKeyArn; }
168 inline bool KmsKeyArnHasBeenSet() const { return m_kmsKeyArnHasBeenSet; }
169 template<typename KmsKeyArnT = Aws::String>
170 void SetKmsKeyArn(KmsKeyArnT&& value) { m_kmsKeyArnHasBeenSet = true; m_kmsKeyArn = std::forward<KmsKeyArnT>(value); }
171 template<typename KmsKeyArnT = Aws::String>
172 StartSnapshotRequest& WithKmsKeyArn(KmsKeyArnT&& value) { SetKmsKeyArn(std::forward<KmsKeyArnT>(value)); return *this;}
174
176
183 inline int GetTimeout() const { return m_timeout; }
184 inline bool TimeoutHasBeenSet() const { return m_timeoutHasBeenSet; }
185 inline void SetTimeout(int value) { m_timeoutHasBeenSet = true; m_timeout = value; }
186 inline StartSnapshotRequest& WithTimeout(int value) { SetTimeout(value); return *this;}
188 private:
189
190 long long m_volumeSize{0};
191 bool m_volumeSizeHasBeenSet = false;
192
193 Aws::String m_parentSnapshotId;
194 bool m_parentSnapshotIdHasBeenSet = false;
195
196 Aws::Vector<Tag> m_tags;
197 bool m_tagsHasBeenSet = false;
198
199 Aws::String m_description;
200 bool m_descriptionHasBeenSet = false;
201
203 bool m_clientTokenHasBeenSet = true;
204
205 bool m_encrypted{false};
206 bool m_encryptedHasBeenSet = false;
207
208 Aws::String m_kmsKeyArn;
209 bool m_kmsKeyArnHasBeenSet = false;
210
211 int m_timeout{0};
212 bool m_timeoutHasBeenSet = false;
213 };
214
215} // namespace Model
216} // namespace EBS
217} // namespace Aws
StartSnapshotRequest & WithVolumeSize(long long value)
StartSnapshotRequest & WithKmsKeyArn(KmsKeyArnT &&value)
StartSnapshotRequest & WithTags(TagsT &&value)
StartSnapshotRequest & WithParentSnapshotId(ParentSnapshotIdT &&value)
StartSnapshotRequest & WithEncrypted(bool value)
StartSnapshotRequest & WithClientToken(ClientTokenT &&value)
const Aws::String & GetDescription() const
virtual const char * GetServiceRequestName() const override
const Aws::String & GetClientToken() const
StartSnapshotRequest & WithTimeout(int value)
AWS_EBS_API Aws::String SerializePayload() const override
StartSnapshotRequest & AddTags(TagsT &&value)
const Aws::String & GetParentSnapshotId() const
StartSnapshotRequest & WithDescription(DescriptionT &&value)
void SetDescription(DescriptionT &&value)
AWS_EBS_API StartSnapshotRequest()=default
void SetParentSnapshotId(ParentSnapshotIdT &&value)
const Aws::Vector< Tag > & GetTags() const
static Aws::Utils::UUID PseudoRandomUUID()
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector