AWS SDK for C++

AWS SDK for C++ Version 1.11.612

Loading...
Searching...
No Matches
CreateBucketRequest.h
1
6#pragma once
7#include <aws/s3control/S3Control_EXPORTS.h>
8#include <aws/s3control/S3ControlRequest.h>
9#include <aws/s3control/model/BucketCannedACL.h>
10#include <aws/core/utils/memory/stl/AWSString.h>
11#include <aws/s3control/model/CreateBucketConfiguration.h>
12#include <utility>
13
14namespace Aws
15{
16namespace S3Control
17{
18namespace Model
19{
20
24 {
25 public:
26 AWS_S3CONTROL_API CreateBucketRequest() = default;
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 "CreateBucket"; }
33
34 AWS_S3CONTROL_API Aws::String SerializePayload() const override;
35
37
38 AWS_S3CONTROL_API inline bool ShouldComputeContentMd5() const override { return true; }
39
43 AWS_S3CONTROL_API EndpointParameters GetEndpointContextParams() const override;
44
46
50 inline BucketCannedACL GetACL() const { return m_aCL; }
51 inline bool ACLHasBeenSet() const { return m_aCLHasBeenSet; }
52 inline void SetACL(BucketCannedACL value) { m_aCLHasBeenSet = true; m_aCL = value; }
53 inline CreateBucketRequest& WithACL(BucketCannedACL value) { SetACL(value); return *this;}
55
57
60 inline const Aws::String& GetBucket() const { return m_bucket; }
61 inline bool BucketHasBeenSet() const { return m_bucketHasBeenSet; }
62 template<typename BucketT = Aws::String>
63 void SetBucket(BucketT&& value) { m_bucketHasBeenSet = true; m_bucket = std::forward<BucketT>(value); }
64 template<typename BucketT = Aws::String>
65 CreateBucketRequest& WithBucket(BucketT&& value) { SetBucket(std::forward<BucketT>(value)); return *this;}
67
69
73 inline const CreateBucketConfiguration& GetCreateBucketConfiguration() const { return m_createBucketConfiguration; }
74 inline bool CreateBucketConfigurationHasBeenSet() const { return m_createBucketConfigurationHasBeenSet; }
75 template<typename CreateBucketConfigurationT = CreateBucketConfiguration>
76 void SetCreateBucketConfiguration(CreateBucketConfigurationT&& value) { m_createBucketConfigurationHasBeenSet = true; m_createBucketConfiguration = std::forward<CreateBucketConfigurationT>(value); }
77 template<typename CreateBucketConfigurationT = CreateBucketConfiguration>
78 CreateBucketRequest& WithCreateBucketConfiguration(CreateBucketConfigurationT&& value) { SetCreateBucketConfiguration(std::forward<CreateBucketConfigurationT>(value)); return *this;}
80
82
87 inline const Aws::String& GetGrantFullControl() const { return m_grantFullControl; }
88 inline bool GrantFullControlHasBeenSet() const { return m_grantFullControlHasBeenSet; }
89 template<typename GrantFullControlT = Aws::String>
90 void SetGrantFullControl(GrantFullControlT&& value) { m_grantFullControlHasBeenSet = true; m_grantFullControl = std::forward<GrantFullControlT>(value); }
91 template<typename GrantFullControlT = Aws::String>
92 CreateBucketRequest& WithGrantFullControl(GrantFullControlT&& value) { SetGrantFullControl(std::forward<GrantFullControlT>(value)); return *this;}
94
96
100 inline const Aws::String& GetGrantRead() const { return m_grantRead; }
101 inline bool GrantReadHasBeenSet() const { return m_grantReadHasBeenSet; }
102 template<typename GrantReadT = Aws::String>
103 void SetGrantRead(GrantReadT&& value) { m_grantReadHasBeenSet = true; m_grantRead = std::forward<GrantReadT>(value); }
104 template<typename GrantReadT = Aws::String>
105 CreateBucketRequest& WithGrantRead(GrantReadT&& value) { SetGrantRead(std::forward<GrantReadT>(value)); return *this;}
107
109
113 inline const Aws::String& GetGrantReadACP() const { return m_grantReadACP; }
114 inline bool GrantReadACPHasBeenSet() const { return m_grantReadACPHasBeenSet; }
115 template<typename GrantReadACPT = Aws::String>
116 void SetGrantReadACP(GrantReadACPT&& value) { m_grantReadACPHasBeenSet = true; m_grantReadACP = std::forward<GrantReadACPT>(value); }
117 template<typename GrantReadACPT = Aws::String>
118 CreateBucketRequest& WithGrantReadACP(GrantReadACPT&& value) { SetGrantReadACP(std::forward<GrantReadACPT>(value)); return *this;}
120
122
126 inline const Aws::String& GetGrantWrite() const { return m_grantWrite; }
127 inline bool GrantWriteHasBeenSet() const { return m_grantWriteHasBeenSet; }
128 template<typename GrantWriteT = Aws::String>
129 void SetGrantWrite(GrantWriteT&& value) { m_grantWriteHasBeenSet = true; m_grantWrite = std::forward<GrantWriteT>(value); }
130 template<typename GrantWriteT = Aws::String>
131 CreateBucketRequest& WithGrantWrite(GrantWriteT&& value) { SetGrantWrite(std::forward<GrantWriteT>(value)); return *this;}
133
135
139 inline const Aws::String& GetGrantWriteACP() const { return m_grantWriteACP; }
140 inline bool GrantWriteACPHasBeenSet() const { return m_grantWriteACPHasBeenSet; }
141 template<typename GrantWriteACPT = Aws::String>
142 void SetGrantWriteACP(GrantWriteACPT&& value) { m_grantWriteACPHasBeenSet = true; m_grantWriteACP = std::forward<GrantWriteACPT>(value); }
143 template<typename GrantWriteACPT = Aws::String>
144 CreateBucketRequest& WithGrantWriteACP(GrantWriteACPT&& value) { SetGrantWriteACP(std::forward<GrantWriteACPT>(value)); return *this;}
146
148
153 inline bool GetObjectLockEnabledForBucket() const { return m_objectLockEnabledForBucket; }
154 inline bool ObjectLockEnabledForBucketHasBeenSet() const { return m_objectLockEnabledForBucketHasBeenSet; }
155 inline void SetObjectLockEnabledForBucket(bool value) { m_objectLockEnabledForBucketHasBeenSet = true; m_objectLockEnabledForBucket = value; }
158
160
164 inline const Aws::String& GetOutpostId() const { return m_outpostId; }
165 inline bool OutpostIdHasBeenSet() const { return m_outpostIdHasBeenSet; }
166 template<typename OutpostIdT = Aws::String>
167 void SetOutpostId(OutpostIdT&& value) { m_outpostIdHasBeenSet = true; m_outpostId = std::forward<OutpostIdT>(value); }
168 template<typename OutpostIdT = Aws::String>
169 CreateBucketRequest& WithOutpostId(OutpostIdT&& value) { SetOutpostId(std::forward<OutpostIdT>(value)); return *this;}
171 private:
172
174 bool m_aCLHasBeenSet = false;
175
176 Aws::String m_bucket;
177 bool m_bucketHasBeenSet = false;
178
179 CreateBucketConfiguration m_createBucketConfiguration;
180 bool m_createBucketConfigurationHasBeenSet = false;
181
182 Aws::String m_grantFullControl;
183 bool m_grantFullControlHasBeenSet = false;
184
185 Aws::String m_grantRead;
186 bool m_grantReadHasBeenSet = false;
187
188 Aws::String m_grantReadACP;
189 bool m_grantReadACPHasBeenSet = false;
190
191 Aws::String m_grantWrite;
192 bool m_grantWriteHasBeenSet = false;
193
194 Aws::String m_grantWriteACP;
195 bool m_grantWriteACPHasBeenSet = false;
196
197 bool m_objectLockEnabledForBucket{false};
198 bool m_objectLockEnabledForBucketHasBeenSet = false;
199
200 Aws::String m_outpostId;
201 bool m_outpostIdHasBeenSet = false;
202 };
203
204} // namespace Model
205} // namespace S3Control
206} // namespace Aws
AWS_S3CONTROL_API bool ShouldComputeContentMd5() const override
AWS_S3CONTROL_API EndpointParameters GetEndpointContextParams() const override
void SetCreateBucketConfiguration(CreateBucketConfigurationT &&value)
CreateBucketRequest & WithACL(BucketCannedACL value)
AWS_S3CONTROL_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
AWS_S3CONTROL_API CreateBucketRequest()=default
CreateBucketRequest & WithGrantWrite(GrantWriteT &&value)
const Aws::String & GetGrantFullControl() const
CreateBucketRequest & WithOutpostId(OutpostIdT &&value)
CreateBucketRequest & WithGrantFullControl(GrantFullControlT &&value)
AWS_S3CONTROL_API Aws::String SerializePayload() const override
CreateBucketRequest & WithCreateBucketConfiguration(CreateBucketConfigurationT &&value)
virtual const char * GetServiceRequestName() const override
CreateBucketRequest & WithGrantRead(GrantReadT &&value)
CreateBucketRequest & WithBucket(BucketT &&value)
CreateBucketRequest & WithGrantReadACP(GrantReadACPT &&value)
CreateBucketRequest & WithGrantWriteACP(GrantWriteACPT &&value)
CreateBucketRequest & WithObjectLockEnabledForBucket(bool value)
const CreateBucketConfiguration & GetCreateBucketConfiguration() const
void SetGrantFullControl(GrantFullControlT &&value)
Aws::Endpoint::EndpointParameters EndpointParameters
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String