AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
PutBucketAclRequest.h
1
6#pragma once
7#include <aws/s3/S3_EXPORTS.h>
8#include <aws/s3/S3Request.h>
9#include <aws/s3/model/BucketCannedACL.h>
10#include <aws/s3/model/AccessControlPolicy.h>
11#include <aws/core/utils/memory/stl/AWSString.h>
12#include <aws/s3/model/ChecksumAlgorithm.h>
13#include <aws/core/utils/memory/stl/AWSMap.h>
14#include <utility>
15
16namespace Aws
17{
18namespace Http
19{
20 class URI;
21} //namespace Http
22namespace S3
23{
24namespace Model
25{
26
30 {
31 public:
32 AWS_S3_API PutBucketAclRequest() = default;
33
34 // Service request name is the Operation name which will send this request out,
35 // each operation should has unique request name, so that we can get operation's name from this request.
36 // Note: this is not true for response, multiple operations may have the same response name,
37 // so we can not get operation's name from response.
38 inline virtual const char* GetServiceRequestName() const override { return "PutBucketAcl"; }
39
40 AWS_S3_API Aws::String SerializePayload() const override;
41
42 AWS_S3_API void AddQueryStringParameters(Aws::Http::URI& uri) const override;
43
45
46 AWS_S3_API bool HasEmbeddedError(IOStream &body, const Http::HeaderValueCollection &header) const override;
47 AWS_S3_API Aws::String GetChecksumAlgorithmName() const override;
48 inline bool RequestChecksumRequired() const override { return true; };
49
53 AWS_S3_API EndpointParameters GetEndpointContextParams() const override;
54
56
59 inline BucketCannedACL GetACL() const { return m_aCL; }
60 inline bool ACLHasBeenSet() const { return m_aCLHasBeenSet; }
61 inline void SetACL(BucketCannedACL value) { m_aCLHasBeenSet = true; m_aCL = value; }
62 inline PutBucketAclRequest& WithACL(BucketCannedACL value) { SetACL(value); return *this;}
64
66
70 inline const AccessControlPolicy& GetAccessControlPolicy() const { return m_accessControlPolicy; }
71 inline bool AccessControlPolicyHasBeenSet() const { return m_accessControlPolicyHasBeenSet; }
72 template<typename AccessControlPolicyT = AccessControlPolicy>
73 void SetAccessControlPolicy(AccessControlPolicyT&& value) { m_accessControlPolicyHasBeenSet = true; m_accessControlPolicy = std::forward<AccessControlPolicyT>(value); }
74 template<typename AccessControlPolicyT = AccessControlPolicy>
75 PutBucketAclRequest& WithAccessControlPolicy(AccessControlPolicyT&& value) { SetAccessControlPolicy(std::forward<AccessControlPolicyT>(value)); return *this;}
77
79
82 inline const Aws::String& GetBucket() const { return m_bucket; }
83 inline bool BucketHasBeenSet() const { return m_bucketHasBeenSet; }
84 template<typename BucketT = Aws::String>
85 void SetBucket(BucketT&& value) { m_bucketHasBeenSet = true; m_bucket = std::forward<BucketT>(value); }
86 template<typename BucketT = Aws::String>
87 PutBucketAclRequest& WithBucket(BucketT&& value) { SetBucket(std::forward<BucketT>(value)); return *this;}
89
91
99 inline const Aws::String& GetContentMD5() const { return m_contentMD5; }
100 inline bool ContentMD5HasBeenSet() const { return m_contentMD5HasBeenSet; }
101 template<typename ContentMD5T = Aws::String>
102 void SetContentMD5(ContentMD5T&& value) { m_contentMD5HasBeenSet = true; m_contentMD5 = std::forward<ContentMD5T>(value); }
103 template<typename ContentMD5T = Aws::String>
104 PutBucketAclRequest& WithContentMD5(ContentMD5T&& value) { SetContentMD5(std::forward<ContentMD5T>(value)); return *this;}
106
108
120 inline ChecksumAlgorithm GetChecksumAlgorithm() const { return m_checksumAlgorithm; }
121 inline bool ChecksumAlgorithmHasBeenSet() const { return m_checksumAlgorithmHasBeenSet; }
122 inline void SetChecksumAlgorithm(ChecksumAlgorithm value) { m_checksumAlgorithmHasBeenSet = true; m_checksumAlgorithm = value; }
125
127
131 inline const Aws::String& GetGrantFullControl() const { return m_grantFullControl; }
132 inline bool GrantFullControlHasBeenSet() const { return m_grantFullControlHasBeenSet; }
133 template<typename GrantFullControlT = Aws::String>
134 void SetGrantFullControl(GrantFullControlT&& value) { m_grantFullControlHasBeenSet = true; m_grantFullControl = std::forward<GrantFullControlT>(value); }
135 template<typename GrantFullControlT = Aws::String>
136 PutBucketAclRequest& WithGrantFullControl(GrantFullControlT&& value) { SetGrantFullControl(std::forward<GrantFullControlT>(value)); return *this;}
138
140
143 inline const Aws::String& GetGrantRead() const { return m_grantRead; }
144 inline bool GrantReadHasBeenSet() const { return m_grantReadHasBeenSet; }
145 template<typename GrantReadT = Aws::String>
146 void SetGrantRead(GrantReadT&& value) { m_grantReadHasBeenSet = true; m_grantRead = std::forward<GrantReadT>(value); }
147 template<typename GrantReadT = Aws::String>
148 PutBucketAclRequest& WithGrantRead(GrantReadT&& value) { SetGrantRead(std::forward<GrantReadT>(value)); return *this;}
150
152
155 inline const Aws::String& GetGrantReadACP() const { return m_grantReadACP; }
156 inline bool GrantReadACPHasBeenSet() const { return m_grantReadACPHasBeenSet; }
157 template<typename GrantReadACPT = Aws::String>
158 void SetGrantReadACP(GrantReadACPT&& value) { m_grantReadACPHasBeenSet = true; m_grantReadACP = std::forward<GrantReadACPT>(value); }
159 template<typename GrantReadACPT = Aws::String>
160 PutBucketAclRequest& WithGrantReadACP(GrantReadACPT&& value) { SetGrantReadACP(std::forward<GrantReadACPT>(value)); return *this;}
162
164
169 inline const Aws::String& GetGrantWrite() const { return m_grantWrite; }
170 inline bool GrantWriteHasBeenSet() const { return m_grantWriteHasBeenSet; }
171 template<typename GrantWriteT = Aws::String>
172 void SetGrantWrite(GrantWriteT&& value) { m_grantWriteHasBeenSet = true; m_grantWrite = std::forward<GrantWriteT>(value); }
173 template<typename GrantWriteT = Aws::String>
174 PutBucketAclRequest& WithGrantWrite(GrantWriteT&& value) { SetGrantWrite(std::forward<GrantWriteT>(value)); return *this;}
176
178
181 inline const Aws::String& GetGrantWriteACP() const { return m_grantWriteACP; }
182 inline bool GrantWriteACPHasBeenSet() const { return m_grantWriteACPHasBeenSet; }
183 template<typename GrantWriteACPT = Aws::String>
184 void SetGrantWriteACP(GrantWriteACPT&& value) { m_grantWriteACPHasBeenSet = true; m_grantWriteACP = std::forward<GrantWriteACPT>(value); }
185 template<typename GrantWriteACPT = Aws::String>
186 PutBucketAclRequest& WithGrantWriteACP(GrantWriteACPT&& value) { SetGrantWriteACP(std::forward<GrantWriteACPT>(value)); return *this;}
188
190
195 inline const Aws::String& GetExpectedBucketOwner() const { return m_expectedBucketOwner; }
196 inline bool ExpectedBucketOwnerHasBeenSet() const { return m_expectedBucketOwnerHasBeenSet; }
197 template<typename ExpectedBucketOwnerT = Aws::String>
198 void SetExpectedBucketOwner(ExpectedBucketOwnerT&& value) { m_expectedBucketOwnerHasBeenSet = true; m_expectedBucketOwner = std::forward<ExpectedBucketOwnerT>(value); }
199 template<typename ExpectedBucketOwnerT = Aws::String>
200 PutBucketAclRequest& WithExpectedBucketOwner(ExpectedBucketOwnerT&& value) { SetExpectedBucketOwner(std::forward<ExpectedBucketOwnerT>(value)); return *this;}
202
204
205 inline const Aws::Map<Aws::String, Aws::String>& GetCustomizedAccessLogTag() const { return m_customizedAccessLogTag; }
206 inline bool CustomizedAccessLogTagHasBeenSet() const { return m_customizedAccessLogTagHasBeenSet; }
207 template<typename CustomizedAccessLogTagT = Aws::Map<Aws::String, Aws::String>>
208 void SetCustomizedAccessLogTag(CustomizedAccessLogTagT&& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag = std::forward<CustomizedAccessLogTagT>(value); }
209 template<typename CustomizedAccessLogTagT = Aws::Map<Aws::String, Aws::String>>
210 PutBucketAclRequest& WithCustomizedAccessLogTag(CustomizedAccessLogTagT&& value) { SetCustomizedAccessLogTag(std::forward<CustomizedAccessLogTagT>(value)); return *this;}
211 template<typename CustomizedAccessLogTagKeyT = Aws::String, typename CustomizedAccessLogTagValueT = Aws::String>
212 PutBucketAclRequest& AddCustomizedAccessLogTag(CustomizedAccessLogTagKeyT&& key, CustomizedAccessLogTagValueT&& value) {
213 m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(std::forward<CustomizedAccessLogTagKeyT>(key), std::forward<CustomizedAccessLogTagValueT>(value)); return *this;
214 }
216 private:
217
219 bool m_aCLHasBeenSet = false;
220
221 AccessControlPolicy m_accessControlPolicy;
222 bool m_accessControlPolicyHasBeenSet = false;
223
224 Aws::String m_bucket;
225 bool m_bucketHasBeenSet = false;
226
227 Aws::String m_contentMD5;
228 bool m_contentMD5HasBeenSet = false;
229
231 bool m_checksumAlgorithmHasBeenSet = false;
232
233 Aws::String m_grantFullControl;
234 bool m_grantFullControlHasBeenSet = false;
235
236 Aws::String m_grantRead;
237 bool m_grantReadHasBeenSet = false;
238
239 Aws::String m_grantReadACP;
240 bool m_grantReadACPHasBeenSet = false;
241
242 Aws::String m_grantWrite;
243 bool m_grantWriteHasBeenSet = false;
244
245 Aws::String m_grantWriteACP;
246 bool m_grantWriteACPHasBeenSet = false;
247
248 Aws::String m_expectedBucketOwner;
249 bool m_expectedBucketOwnerHasBeenSet = false;
250
251 Aws::Map<Aws::String, Aws::String> m_customizedAccessLogTag;
252 bool m_customizedAccessLogTagHasBeenSet = false;
253 };
254
255} // namespace Model
256} // namespace S3
257} // namespace Aws
ChecksumAlgorithm GetChecksumAlgorithm() const
AWS_S3_API void AddQueryStringParameters(Aws::Http::URI &uri) const override
void SetCustomizedAccessLogTag(CustomizedAccessLogTagT &&value)
void SetAccessControlPolicy(AccessControlPolicyT &&value)
virtual const char * GetServiceRequestName() const override
AWS_S3_API EndpointParameters GetEndpointContextParams() const override
AWS_S3_API Aws::String SerializePayload() const override
PutBucketAclRequest & WithGrantFullControl(GrantFullControlT &&value)
const Aws::String & GetContentMD5() const
const Aws::String & GetBucket() const
void SetGrantReadACP(GrantReadACPT &&value)
PutBucketAclRequest & WithChecksumAlgorithm(ChecksumAlgorithm value)
const AccessControlPolicy & GetAccessControlPolicy() const
const Aws::String & GetGrantWrite() const
PutBucketAclRequest & AddCustomizedAccessLogTag(CustomizedAccessLogTagKeyT &&key, CustomizedAccessLogTagValueT &&value)
void SetGrantWriteACP(GrantWriteACPT &&value)
void SetGrantWrite(GrantWriteT &&value)
AWS_S3_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
void SetACL(BucketCannedACL value)
const Aws::String & GetGrantRead() const
PutBucketAclRequest & WithGrantWriteACP(GrantWriteACPT &&value)
void SetChecksumAlgorithm(ChecksumAlgorithm value)
PutBucketAclRequest & WithGrantReadACP(GrantReadACPT &&value)
PutBucketAclRequest & WithGrantWrite(GrantWriteT &&value)
PutBucketAclRequest & WithACL(BucketCannedACL value)
PutBucketAclRequest & WithBucket(BucketT &&value)
const Aws::String & GetGrantReadACP() const
const Aws::String & GetGrantFullControl() const
PutBucketAclRequest & WithAccessControlPolicy(AccessControlPolicyT &&value)
const Aws::String & GetGrantWriteACP() const
AWS_S3_API bool HasEmbeddedError(IOStream &body, const Http::HeaderValueCollection &header) const override
PutBucketAclRequest & WithContentMD5(ContentMD5T &&value)
AWS_S3_API PutBucketAclRequest()=default
void SetContentMD5(ContentMD5T &&value)
void SetGrantFullControl(GrantFullControlT &&value)
const Aws::String & GetExpectedBucketOwner() const
bool RequestChecksumRequired() const override
PutBucketAclRequest & WithGrantRead(GrantReadT &&value)
AWS_S3_API Aws::String GetChecksumAlgorithmName() const override
const Aws::Map< Aws::String, Aws::String > & GetCustomizedAccessLogTag() const
PutBucketAclRequest & WithExpectedBucketOwner(ExpectedBucketOwnerT &&value)
PutBucketAclRequest & WithCustomizedAccessLogTag(CustomizedAccessLogTagT &&value)
void SetExpectedBucketOwner(ExpectedBucketOwnerT &&value)
Aws::Endpoint::EndpointParameters EndpointParameters
Definition S3Request.h:22
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_iostream< char, std::char_traits< char > > IOStream
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String