AWS SDK for C++
AWS SDK for C++
Loading...
Searching...
No Matches
CreateBucketRequest.h
Go to the documentation of this file.
1
6#pragma once
7#include <aws/s3/S3_EXPORTS.h>
8#include <aws/s3/S3Request.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:
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 "CreateBucket"; }
39
41
43
45
50
54 inline const BucketCannedACL& GetACL() const{ return m_aCL; }
55
59 inline bool ACLHasBeenSet() const { return m_aCLHasBeenSet; }
60
64 inline void SetACL(const BucketCannedACL& value) { m_aCLHasBeenSet = true; m_aCL = value; }
65
69 inline void SetACL(BucketCannedACL&& value) { m_aCLHasBeenSet = true; m_aCL = std::move(value); }
70
74 inline CreateBucketRequest& WithACL(const BucketCannedACL& value) { SetACL(value); return *this;}
75
79 inline CreateBucketRequest& WithACL(BucketCannedACL&& value) { SetACL(std::move(value)); return *this;}
80
81
85 inline const Aws::String& GetBucket() const{ return m_bucket; }
86
90 inline bool BucketHasBeenSet() const { return m_bucketHasBeenSet; }
91
95 inline void SetBucket(const Aws::String& value) { m_bucketHasBeenSet = true; m_bucket = value; }
96
100 inline void SetBucket(Aws::String&& value) { m_bucketHasBeenSet = true; m_bucket = std::move(value); }
101
105 inline void SetBucket(const char* value) { m_bucketHasBeenSet = true; m_bucket.assign(value); }
106
110 inline CreateBucketRequest& WithBucket(const Aws::String& value) { SetBucket(value); return *this;}
111
115 inline CreateBucketRequest& WithBucket(Aws::String&& value) { SetBucket(std::move(value)); return *this;}
116
120 inline CreateBucketRequest& WithBucket(const char* value) { SetBucket(value); return *this;}
121
122
126 inline const CreateBucketConfiguration& GetCreateBucketConfiguration() const{ return m_createBucketConfiguration; }
127
131 inline bool CreateBucketConfigurationHasBeenSet() const { return m_createBucketConfigurationHasBeenSet; }
132
136 inline void SetCreateBucketConfiguration(const CreateBucketConfiguration& value) { m_createBucketConfigurationHasBeenSet = true; m_createBucketConfiguration = value; }
137
141 inline void SetCreateBucketConfiguration(CreateBucketConfiguration&& value) { m_createBucketConfigurationHasBeenSet = true; m_createBucketConfiguration = std::move(value); }
142
147
152
153
158 inline const Aws::String& GetGrantFullControl() const{ return m_grantFullControl; }
159
164 inline bool GrantFullControlHasBeenSet() const { return m_grantFullControlHasBeenSet; }
165
170 inline void SetGrantFullControl(const Aws::String& value) { m_grantFullControlHasBeenSet = true; m_grantFullControl = value; }
171
176 inline void SetGrantFullControl(Aws::String&& value) { m_grantFullControlHasBeenSet = true; m_grantFullControl = std::move(value); }
177
182 inline void SetGrantFullControl(const char* value) { m_grantFullControlHasBeenSet = true; m_grantFullControl.assign(value); }
183
188 inline CreateBucketRequest& WithGrantFullControl(const Aws::String& value) { SetGrantFullControl(value); return *this;}
189
194 inline CreateBucketRequest& WithGrantFullControl(Aws::String&& value) { SetGrantFullControl(std::move(value)); return *this;}
195
200 inline CreateBucketRequest& WithGrantFullControl(const char* value) { SetGrantFullControl(value); return *this;}
201
202
206 inline const Aws::String& GetGrantRead() const{ return m_grantRead; }
207
211 inline bool GrantReadHasBeenSet() const { return m_grantReadHasBeenSet; }
212
216 inline void SetGrantRead(const Aws::String& value) { m_grantReadHasBeenSet = true; m_grantRead = value; }
217
221 inline void SetGrantRead(Aws::String&& value) { m_grantReadHasBeenSet = true; m_grantRead = std::move(value); }
222
226 inline void SetGrantRead(const char* value) { m_grantReadHasBeenSet = true; m_grantRead.assign(value); }
227
231 inline CreateBucketRequest& WithGrantRead(const Aws::String& value) { SetGrantRead(value); return *this;}
232
236 inline CreateBucketRequest& WithGrantRead(Aws::String&& value) { SetGrantRead(std::move(value)); return *this;}
237
241 inline CreateBucketRequest& WithGrantRead(const char* value) { SetGrantRead(value); return *this;}
242
243
247 inline const Aws::String& GetGrantReadACP() const{ return m_grantReadACP; }
248
252 inline bool GrantReadACPHasBeenSet() const { return m_grantReadACPHasBeenSet; }
253
257 inline void SetGrantReadACP(const Aws::String& value) { m_grantReadACPHasBeenSet = true; m_grantReadACP = value; }
258
262 inline void SetGrantReadACP(Aws::String&& value) { m_grantReadACPHasBeenSet = true; m_grantReadACP = std::move(value); }
263
267 inline void SetGrantReadACP(const char* value) { m_grantReadACPHasBeenSet = true; m_grantReadACP.assign(value); }
268
272 inline CreateBucketRequest& WithGrantReadACP(const Aws::String& value) { SetGrantReadACP(value); return *this;}
273
277 inline CreateBucketRequest& WithGrantReadACP(Aws::String&& value) { SetGrantReadACP(std::move(value)); return *this;}
278
282 inline CreateBucketRequest& WithGrantReadACP(const char* value) { SetGrantReadACP(value); return *this;}
283
284
290 inline const Aws::String& GetGrantWrite() const{ return m_grantWrite; }
291
297 inline bool GrantWriteHasBeenSet() const { return m_grantWriteHasBeenSet; }
298
304 inline void SetGrantWrite(const Aws::String& value) { m_grantWriteHasBeenSet = true; m_grantWrite = value; }
305
311 inline void SetGrantWrite(Aws::String&& value) { m_grantWriteHasBeenSet = true; m_grantWrite = std::move(value); }
312
318 inline void SetGrantWrite(const char* value) { m_grantWriteHasBeenSet = true; m_grantWrite.assign(value); }
319
325 inline CreateBucketRequest& WithGrantWrite(const Aws::String& value) { SetGrantWrite(value); return *this;}
326
332 inline CreateBucketRequest& WithGrantWrite(Aws::String&& value) { SetGrantWrite(std::move(value)); return *this;}
333
339 inline CreateBucketRequest& WithGrantWrite(const char* value) { SetGrantWrite(value); return *this;}
340
341
345 inline const Aws::String& GetGrantWriteACP() const{ return m_grantWriteACP; }
346
350 inline bool GrantWriteACPHasBeenSet() const { return m_grantWriteACPHasBeenSet; }
351
355 inline void SetGrantWriteACP(const Aws::String& value) { m_grantWriteACPHasBeenSet = true; m_grantWriteACP = value; }
356
360 inline void SetGrantWriteACP(Aws::String&& value) { m_grantWriteACPHasBeenSet = true; m_grantWriteACP = std::move(value); }
361
365 inline void SetGrantWriteACP(const char* value) { m_grantWriteACPHasBeenSet = true; m_grantWriteACP.assign(value); }
366
370 inline CreateBucketRequest& WithGrantWriteACP(const Aws::String& value) { SetGrantWriteACP(value); return *this;}
371
375 inline CreateBucketRequest& WithGrantWriteACP(Aws::String&& value) { SetGrantWriteACP(std::move(value)); return *this;}
376
380 inline CreateBucketRequest& WithGrantWriteACP(const char* value) { SetGrantWriteACP(value); return *this;}
381
382
387 inline bool GetObjectLockEnabledForBucket() const{ return m_objectLockEnabledForBucket; }
388
393 inline bool ObjectLockEnabledForBucketHasBeenSet() const { return m_objectLockEnabledForBucketHasBeenSet; }
394
399 inline void SetObjectLockEnabledForBucket(bool value) { m_objectLockEnabledForBucketHasBeenSet = true; m_objectLockEnabledForBucket = value; }
400
406
407
408
409 inline const ObjectOwnership& GetObjectOwnership() const{ return m_objectOwnership; }
410
411
412 inline bool ObjectOwnershipHasBeenSet() const { return m_objectOwnershipHasBeenSet; }
413
414
415 inline void SetObjectOwnership(const ObjectOwnership& value) { m_objectOwnershipHasBeenSet = true; m_objectOwnership = value; }
416
417
418 inline void SetObjectOwnership(ObjectOwnership&& value) { m_objectOwnershipHasBeenSet = true; m_objectOwnership = std::move(value); }
419
420
421 inline CreateBucketRequest& WithObjectOwnership(const ObjectOwnership& value) { SetObjectOwnership(value); return *this;}
422
423
424 inline CreateBucketRequest& WithObjectOwnership(ObjectOwnership&& value) { SetObjectOwnership(std::move(value)); return *this;}
425
426
427
428 inline const Aws::Map<Aws::String, Aws::String>& GetCustomizedAccessLogTag() const{ return m_customizedAccessLogTag; }
429
430
431 inline bool CustomizedAccessLogTagHasBeenSet() const { return m_customizedAccessLogTagHasBeenSet; }
432
433
434 inline void SetCustomizedAccessLogTag(const Aws::Map<Aws::String, Aws::String>& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag = value; }
435
436
437 inline void SetCustomizedAccessLogTag(Aws::Map<Aws::String, Aws::String>&& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag = std::move(value); }
438
439
441
442
444
445
446 inline CreateBucketRequest& AddCustomizedAccessLogTag(const Aws::String& key, const Aws::String& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(key, value); return *this; }
447
448
449 inline CreateBucketRequest& AddCustomizedAccessLogTag(Aws::String&& key, const Aws::String& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(std::move(key), value); return *this; }
450
451
452 inline CreateBucketRequest& AddCustomizedAccessLogTag(const Aws::String& key, Aws::String&& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(key, std::move(value)); return *this; }
453
454
455 inline CreateBucketRequest& AddCustomizedAccessLogTag(Aws::String&& key, Aws::String&& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(std::move(key), std::move(value)); return *this; }
456
457
458 inline CreateBucketRequest& AddCustomizedAccessLogTag(const char* key, Aws::String&& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(key, std::move(value)); return *this; }
459
460
461 inline CreateBucketRequest& AddCustomizedAccessLogTag(Aws::String&& key, const char* value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(std::move(key), value); return *this; }
462
463
464 inline CreateBucketRequest& AddCustomizedAccessLogTag(const char* key, const char* value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(key, value); return *this; }
465
466 private:
467
468 BucketCannedACL m_aCL;
469 bool m_aCLHasBeenSet = false;
470
471 Aws::String m_bucket;
472 bool m_bucketHasBeenSet = false;
473
474 CreateBucketConfiguration m_createBucketConfiguration;
475 bool m_createBucketConfigurationHasBeenSet = false;
476
477 Aws::String m_grantFullControl;
478 bool m_grantFullControlHasBeenSet = false;
479
480 Aws::String m_grantRead;
481 bool m_grantReadHasBeenSet = false;
482
483 Aws::String m_grantReadACP;
484 bool m_grantReadACPHasBeenSet = false;
485
486 Aws::String m_grantWrite;
487 bool m_grantWriteHasBeenSet = false;
488
489 Aws::String m_grantWriteACP;
490 bool m_grantWriteACPHasBeenSet = false;
491
492 bool m_objectLockEnabledForBucket;
493 bool m_objectLockEnabledForBucketHasBeenSet = false;
494
495 ObjectOwnership m_objectOwnership;
496 bool m_objectOwnershipHasBeenSet = false;
497
498 Aws::Map<Aws::String, Aws::String> m_customizedAccessLogTag;
499 bool m_customizedAccessLogTagHasBeenSet = false;
500 };
501
502} // namespace Model
503} // namespace S3
504} // namespace Aws
#define AWS_S3_API
Definition: S3_EXPORTS.h:28
void SetGrantFullControl(const char *value)
void SetACL(const BucketCannedACL &value)
const BucketCannedACL & GetACL() const
AWS_S3_API void AddQueryStringParameters(Aws::Http::URI &uri) const override
CreateBucketRequest & WithGrantWrite(Aws::String &&value)
CreateBucketRequest & WithGrantReadACP(const char *value)
void SetACL(BucketCannedACL &&value)
void SetCreateBucketConfiguration(CreateBucketConfiguration &&value)
void SetCustomizedAccessLogTag(const Aws::Map< Aws::String, Aws::String > &value)
CreateBucketRequest & WithObjectOwnership(const ObjectOwnership &value)
const Aws::String & GetBucket() const
void SetCustomizedAccessLogTag(Aws::Map< Aws::String, Aws::String > &&value)
CreateBucketRequest & WithACL(BucketCannedACL &&value)
const Aws::Map< Aws::String, Aws::String > & GetCustomizedAccessLogTag() const
void SetCreateBucketConfiguration(const CreateBucketConfiguration &value)
void SetGrantWriteACP(Aws::String &&value)
CreateBucketRequest & WithGrantReadACP(const Aws::String &value)
CreateBucketRequest & WithGrantWriteACP(const Aws::String &value)
CreateBucketRequest & AddCustomizedAccessLogTag(const char *key, Aws::String &&value)
CreateBucketRequest & WithCreateBucketConfiguration(CreateBucketConfiguration &&value)
CreateBucketRequest & AddCustomizedAccessLogTag(Aws::String &&key, Aws::String &&value)
CreateBucketRequest & WithCustomizedAccessLogTag(const Aws::Map< Aws::String, Aws::String > &value)
void SetGrantReadACP(const Aws::String &value)
const Aws::String & GetGrantFullControl() const
const ObjectOwnership & GetObjectOwnership() const
CreateBucketRequest & AddCustomizedAccessLogTag(Aws::String &&key, const Aws::String &value)
AWS_S3_API Aws::String SerializePayload() const override
const Aws::String & GetGrantReadACP() const
void SetGrantRead(const Aws::String &value)
CreateBucketRequest & WithGrantFullControl(Aws::String &&value)
CreateBucketRequest & AddCustomizedAccessLogTag(const Aws::String &key, const Aws::String &value)
CreateBucketRequest & WithGrantRead(const Aws::String &value)
void SetGrantFullControl(const Aws::String &value)
const Aws::String & GetGrantRead() const
void SetGrantRead(Aws::String &&value)
virtual const char * GetServiceRequestName() const override
void SetObjectOwnership(ObjectOwnership &&value)
void SetGrantWriteACP(const Aws::String &value)
CreateBucketRequest & WithObjectLockEnabledForBucket(bool value)
CreateBucketRequest & WithBucket(Aws::String &&value)
void SetGrantFullControl(Aws::String &&value)
void SetGrantReadACP(Aws::String &&value)
AWS_S3_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
CreateBucketRequest & WithGrantReadACP(Aws::String &&value)
CreateBucketRequest & WithACL(const BucketCannedACL &value)
CreateBucketRequest & WithGrantWriteACP(Aws::String &&value)
void SetGrantWrite(const Aws::String &value)
CreateBucketRequest & AddCustomizedAccessLogTag(const Aws::String &key, Aws::String &&value)
void SetObjectOwnership(const ObjectOwnership &value)
CreateBucketRequest & WithGrantWrite(const Aws::String &value)
CreateBucketRequest & WithGrantWriteACP(const char *value)
CreateBucketRequest & WithBucket(const Aws::String &value)
const Aws::String & GetGrantWrite() const
CreateBucketRequest & AddCustomizedAccessLogTag(const char *key, const char *value)
void SetGrantWrite(Aws::String &&value)
CreateBucketRequest & WithBucket(const char *value)
const CreateBucketConfiguration & GetCreateBucketConfiguration() const
CreateBucketRequest & WithObjectOwnership(ObjectOwnership &&value)
CreateBucketRequest & WithGrantRead(Aws::String &&value)
const Aws::String & GetGrantWriteACP() const
CreateBucketRequest & WithCreateBucketConfiguration(const CreateBucketConfiguration &value)
CreateBucketRequest & WithGrantFullControl(const char *value)
CreateBucketRequest & WithGrantWrite(const char *value)
CreateBucketRequest & WithGrantFullControl(const Aws::String &value)
CreateBucketRequest & WithCustomizedAccessLogTag(Aws::Map< Aws::String, Aws::String > &&value)
void SetGrantWriteACP(const char *value)
CreateBucketRequest & AddCustomizedAccessLogTag(Aws::String &&key, const char *value)
void SetBucket(const Aws::String &value)
AWS_S3_API EndpointParameters GetEndpointContextParams() const override
CreateBucketRequest & WithGrantRead(const char *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_string< char, std::char_traits< char >, Aws::Allocator< char > > String