AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
PutBucketEncryptionRequest.h
1
6#pragma once
7#include <aws/s3/S3_EXPORTS.h>
8#include <aws/s3/S3Request.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/s3/model/ChecksumAlgorithm.h>
11#include <aws/s3/model/ServerSideEncryptionConfiguration.h>
12#include <aws/core/utils/memory/stl/AWSMap.h>
13#include <utility>
14
15namespace Aws
16{
17namespace Http
18{
19 class URI;
20} //namespace Http
21namespace S3
22{
23namespace Model
24{
25
29 {
30 public:
31 AWS_S3_API PutBucketEncryptionRequest() = default;
32
33 // Service request name is the Operation name which will send this request out,
34 // each operation should has unique request name, so that we can get operation's name from this request.
35 // Note: this is not true for response, multiple operations may have the same response name,
36 // so we can not get operation's name from response.
37 inline virtual const char* GetServiceRequestName() const override { return "PutBucketEncryption"; }
38
39 AWS_S3_API Aws::String SerializePayload() const override;
40
41 AWS_S3_API void AddQueryStringParameters(Aws::Http::URI& uri) const override;
42
44
45 AWS_S3_API bool HasEmbeddedError(IOStream &body, const Http::HeaderValueCollection &header) const override;
46 AWS_S3_API Aws::String GetChecksumAlgorithmName() const override;
47 inline bool RequestChecksumRequired() const override { return true; };
48
52 AWS_S3_API EndpointParameters GetEndpointContextParams() const override;
53
55
70 inline const Aws::String& GetBucket() const { return m_bucket; }
71 inline bool BucketHasBeenSet() const { return m_bucketHasBeenSet; }
72 template<typename BucketT = Aws::String>
73 void SetBucket(BucketT&& value) { m_bucketHasBeenSet = true; m_bucket = std::forward<BucketT>(value); }
74 template<typename BucketT = Aws::String>
75 PutBucketEncryptionRequest& WithBucket(BucketT&& value) { SetBucket(std::forward<BucketT>(value)); return *this;}
77
79
86 inline const Aws::String& GetContentMD5() const { return m_contentMD5; }
87 inline bool ContentMD5HasBeenSet() const { return m_contentMD5HasBeenSet; }
88 template<typename ContentMD5T = Aws::String>
89 void SetContentMD5(ContentMD5T&& value) { m_contentMD5HasBeenSet = true; m_contentMD5 = std::forward<ContentMD5T>(value); }
90 template<typename ContentMD5T = Aws::String>
91 PutBucketEncryptionRequest& WithContentMD5(ContentMD5T&& value) { SetContentMD5(std::forward<ContentMD5T>(value)); return *this;}
93
95
109 inline ChecksumAlgorithm GetChecksumAlgorithm() const { return m_checksumAlgorithm; }
110 inline bool ChecksumAlgorithmHasBeenSet() const { return m_checksumAlgorithmHasBeenSet; }
111 inline void SetChecksumAlgorithm(ChecksumAlgorithm value) { m_checksumAlgorithmHasBeenSet = true; m_checksumAlgorithm = value; }
114
116
117 inline const ServerSideEncryptionConfiguration& GetServerSideEncryptionConfiguration() const { return m_serverSideEncryptionConfiguration; }
118 inline bool ServerSideEncryptionConfigurationHasBeenSet() const { return m_serverSideEncryptionConfigurationHasBeenSet; }
119 template<typename ServerSideEncryptionConfigurationT = ServerSideEncryptionConfiguration>
120 void SetServerSideEncryptionConfiguration(ServerSideEncryptionConfigurationT&& value) { m_serverSideEncryptionConfigurationHasBeenSet = true; m_serverSideEncryptionConfiguration = std::forward<ServerSideEncryptionConfigurationT>(value); }
121 template<typename ServerSideEncryptionConfigurationT = ServerSideEncryptionConfiguration>
122 PutBucketEncryptionRequest& WithServerSideEncryptionConfiguration(ServerSideEncryptionConfigurationT&& value) { SetServerSideEncryptionConfiguration(std::forward<ServerSideEncryptionConfigurationT>(value)); return *this;}
124
126
134 inline const Aws::String& GetExpectedBucketOwner() const { return m_expectedBucketOwner; }
135 inline bool ExpectedBucketOwnerHasBeenSet() const { return m_expectedBucketOwnerHasBeenSet; }
136 template<typename ExpectedBucketOwnerT = Aws::String>
137 void SetExpectedBucketOwner(ExpectedBucketOwnerT&& value) { m_expectedBucketOwnerHasBeenSet = true; m_expectedBucketOwner = std::forward<ExpectedBucketOwnerT>(value); }
138 template<typename ExpectedBucketOwnerT = Aws::String>
139 PutBucketEncryptionRequest& WithExpectedBucketOwner(ExpectedBucketOwnerT&& value) { SetExpectedBucketOwner(std::forward<ExpectedBucketOwnerT>(value)); return *this;}
141
143
144 inline const Aws::Map<Aws::String, Aws::String>& GetCustomizedAccessLogTag() const { return m_customizedAccessLogTag; }
145 inline bool CustomizedAccessLogTagHasBeenSet() const { return m_customizedAccessLogTagHasBeenSet; }
146 template<typename CustomizedAccessLogTagT = Aws::Map<Aws::String, Aws::String>>
147 void SetCustomizedAccessLogTag(CustomizedAccessLogTagT&& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag = std::forward<CustomizedAccessLogTagT>(value); }
148 template<typename CustomizedAccessLogTagT = Aws::Map<Aws::String, Aws::String>>
149 PutBucketEncryptionRequest& WithCustomizedAccessLogTag(CustomizedAccessLogTagT&& value) { SetCustomizedAccessLogTag(std::forward<CustomizedAccessLogTagT>(value)); return *this;}
150 template<typename CustomizedAccessLogTagKeyT = Aws::String, typename CustomizedAccessLogTagValueT = Aws::String>
151 PutBucketEncryptionRequest& AddCustomizedAccessLogTag(CustomizedAccessLogTagKeyT&& key, CustomizedAccessLogTagValueT&& value) {
152 m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(std::forward<CustomizedAccessLogTagKeyT>(key), std::forward<CustomizedAccessLogTagValueT>(value)); return *this;
153 }
155 private:
156
157 Aws::String m_bucket;
158 bool m_bucketHasBeenSet = false;
159
160 Aws::String m_contentMD5;
161 bool m_contentMD5HasBeenSet = false;
162
164 bool m_checksumAlgorithmHasBeenSet = false;
165
166 ServerSideEncryptionConfiguration m_serverSideEncryptionConfiguration;
167 bool m_serverSideEncryptionConfigurationHasBeenSet = false;
168
169 Aws::String m_expectedBucketOwner;
170 bool m_expectedBucketOwnerHasBeenSet = false;
171
172 Aws::Map<Aws::String, Aws::String> m_customizedAccessLogTag;
173 bool m_customizedAccessLogTagHasBeenSet = false;
174 };
175
176} // namespace Model
177} // namespace S3
178} // namespace Aws
PutBucketEncryptionRequest & WithContentMD5(ContentMD5T &&value)
AWS_S3_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
PutBucketEncryptionRequest & WithCustomizedAccessLogTag(CustomizedAccessLogTagT &&value)
PutBucketEncryptionRequest & WithBucket(BucketT &&value)
virtual const char * GetServiceRequestName() const override
AWS_S3_API Aws::String GetChecksumAlgorithmName() const override
AWS_S3_API bool HasEmbeddedError(IOStream &body, const Http::HeaderValueCollection &header) const override
void SetCustomizedAccessLogTag(CustomizedAccessLogTagT &&value)
PutBucketEncryptionRequest & WithChecksumAlgorithm(ChecksumAlgorithm value)
AWS_S3_API EndpointParameters GetEndpointContextParams() const override
PutBucketEncryptionRequest & WithServerSideEncryptionConfiguration(ServerSideEncryptionConfigurationT &&value)
PutBucketEncryptionRequest & WithExpectedBucketOwner(ExpectedBucketOwnerT &&value)
AWS_S3_API void AddQueryStringParameters(Aws::Http::URI &uri) const override
AWS_S3_API Aws::String SerializePayload() const override
PutBucketEncryptionRequest & AddCustomizedAccessLogTag(CustomizedAccessLogTagKeyT &&key, CustomizedAccessLogTagValueT &&value)
AWS_S3_API PutBucketEncryptionRequest()=default
void SetExpectedBucketOwner(ExpectedBucketOwnerT &&value)
const ServerSideEncryptionConfiguration & GetServerSideEncryptionConfiguration() const
void SetServerSideEncryptionConfiguration(ServerSideEncryptionConfigurationT &&value)
const Aws::Map< Aws::String, Aws::String > & GetCustomizedAccessLogTag() const
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