AWS SDK for C++  1.8.71
AWS SDK for C++
PutBucketLifecycleConfigurationRequest.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>
12 #include <utility>
13 
14 namespace Aws
15 {
16 namespace Http
17 {
18  class URI;
19 } //namespace Http
20 namespace S3
21 {
22 namespace Model
23 {
24 
28  {
29  public:
31 
32  // Service request name is the Operation name which will send this request out,
33  // each operation should has unique request name, so that we can get operation's name from this request.
34  // Note: this is not true for response, multiple operations may have the same response name,
35  // so we can not get operation's name from response.
36  inline virtual const char* GetServiceRequestName() const override { return "PutBucketLifecycleConfiguration"; }
37 
38  Aws::String SerializePayload() const override;
39 
40  void AddQueryStringParameters(Aws::Http::URI& uri) const override;
41 
42  Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
43 
44  inline bool ShouldComputeContentMd5() const override { return true; }
45 
46 
50  inline const Aws::String& GetBucket() const{ return m_bucket; }
51 
55  inline bool BucketHasBeenSet() const { return m_bucketHasBeenSet; }
56 
60  inline void SetBucket(const Aws::String& value) { m_bucketHasBeenSet = true; m_bucket = value; }
61 
65  inline void SetBucket(Aws::String&& value) { m_bucketHasBeenSet = true; m_bucket = std::move(value); }
66 
70  inline void SetBucket(const char* value) { m_bucketHasBeenSet = true; m_bucket.assign(value); }
71 
75  inline PutBucketLifecycleConfigurationRequest& WithBucket(const Aws::String& value) { SetBucket(value); return *this;}
76 
80  inline PutBucketLifecycleConfigurationRequest& WithBucket(Aws::String&& value) { SetBucket(std::move(value)); return *this;}
81 
85  inline PutBucketLifecycleConfigurationRequest& WithBucket(const char* value) { SetBucket(value); return *this;}
86 
87 
91  inline const BucketLifecycleConfiguration& GetLifecycleConfiguration() const{ return m_lifecycleConfiguration; }
92 
96  inline bool LifecycleConfigurationHasBeenSet() const { return m_lifecycleConfigurationHasBeenSet; }
97 
101  inline void SetLifecycleConfiguration(const BucketLifecycleConfiguration& value) { m_lifecycleConfigurationHasBeenSet = true; m_lifecycleConfiguration = value; }
102 
106  inline void SetLifecycleConfiguration(BucketLifecycleConfiguration&& value) { m_lifecycleConfigurationHasBeenSet = true; m_lifecycleConfiguration = std::move(value); }
107 
111  inline PutBucketLifecycleConfigurationRequest& WithLifecycleConfiguration(const BucketLifecycleConfiguration& value) { SetLifecycleConfiguration(value); return *this;}
112 
116  inline PutBucketLifecycleConfigurationRequest& WithLifecycleConfiguration(BucketLifecycleConfiguration&& value) { SetLifecycleConfiguration(std::move(value)); return *this;}
117 
118 
124  inline const Aws::String& GetExpectedBucketOwner() const{ return m_expectedBucketOwner; }
125 
131  inline bool ExpectedBucketOwnerHasBeenSet() const { return m_expectedBucketOwnerHasBeenSet; }
132 
138  inline void SetExpectedBucketOwner(const Aws::String& value) { m_expectedBucketOwnerHasBeenSet = true; m_expectedBucketOwner = value; }
139 
145  inline void SetExpectedBucketOwner(Aws::String&& value) { m_expectedBucketOwnerHasBeenSet = true; m_expectedBucketOwner = std::move(value); }
146 
152  inline void SetExpectedBucketOwner(const char* value) { m_expectedBucketOwnerHasBeenSet = true; m_expectedBucketOwner.assign(value); }
153 
159  inline PutBucketLifecycleConfigurationRequest& WithExpectedBucketOwner(const Aws::String& value) { SetExpectedBucketOwner(value); return *this;}
160 
166  inline PutBucketLifecycleConfigurationRequest& WithExpectedBucketOwner(Aws::String&& value) { SetExpectedBucketOwner(std::move(value)); return *this;}
167 
173  inline PutBucketLifecycleConfigurationRequest& WithExpectedBucketOwner(const char* value) { SetExpectedBucketOwner(value); return *this;}
174 
175 
176 
177  inline const Aws::Map<Aws::String, Aws::String>& GetCustomizedAccessLogTag() const{ return m_customizedAccessLogTag; }
178 
179 
180  inline bool CustomizedAccessLogTagHasBeenSet() const { return m_customizedAccessLogTagHasBeenSet; }
181 
182 
183  inline void SetCustomizedAccessLogTag(const Aws::Map<Aws::String, Aws::String>& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag = value; }
184 
185 
186  inline void SetCustomizedAccessLogTag(Aws::Map<Aws::String, Aws::String>&& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag = std::move(value); }
187 
188 
189  inline PutBucketLifecycleConfigurationRequest& WithCustomizedAccessLogTag(const Aws::Map<Aws::String, Aws::String>& value) { SetCustomizedAccessLogTag(value); return *this;}
190 
191 
192  inline PutBucketLifecycleConfigurationRequest& WithCustomizedAccessLogTag(Aws::Map<Aws::String, Aws::String>&& value) { SetCustomizedAccessLogTag(std::move(value)); return *this;}
193 
194 
195  inline PutBucketLifecycleConfigurationRequest& AddCustomizedAccessLogTag(const Aws::String& key, const Aws::String& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(key, value); return *this; }
196 
197 
198  inline PutBucketLifecycleConfigurationRequest& AddCustomizedAccessLogTag(Aws::String&& key, const Aws::String& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(std::move(key), value); return *this; }
199 
200 
201  inline PutBucketLifecycleConfigurationRequest& AddCustomizedAccessLogTag(const Aws::String& key, Aws::String&& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(key, std::move(value)); return *this; }
202 
203 
204  inline PutBucketLifecycleConfigurationRequest& AddCustomizedAccessLogTag(Aws::String&& key, Aws::String&& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(std::move(key), std::move(value)); return *this; }
205 
206 
207  inline PutBucketLifecycleConfigurationRequest& AddCustomizedAccessLogTag(const char* key, Aws::String&& value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(key, std::move(value)); return *this; }
208 
209 
210  inline PutBucketLifecycleConfigurationRequest& AddCustomizedAccessLogTag(Aws::String&& key, const char* value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(std::move(key), value); return *this; }
211 
212 
213  inline PutBucketLifecycleConfigurationRequest& AddCustomizedAccessLogTag(const char* key, const char* value) { m_customizedAccessLogTagHasBeenSet = true; m_customizedAccessLogTag.emplace(key, value); return *this; }
214 
215  private:
216 
217  Aws::String m_bucket;
218  bool m_bucketHasBeenSet;
219 
220  BucketLifecycleConfiguration m_lifecycleConfiguration;
221  bool m_lifecycleConfigurationHasBeenSet;
222 
223  Aws::String m_expectedBucketOwner;
224  bool m_expectedBucketOwnerHasBeenSet;
225 
226  Aws::Map<Aws::String, Aws::String> m_customizedAccessLogTag;
227  bool m_customizedAccessLogTagHasBeenSet;
228  };
229 
230 } // namespace Model
231 } // namespace S3
232 } // namespace Aws
PutBucketLifecycleConfigurationRequest & AddCustomizedAccessLogTag(const char *key, Aws::String &&value)
PutBucketLifecycleConfigurationRequest & WithBucket(Aws::String &&value)
void SetCustomizedAccessLogTag(Aws::Map< Aws::String, Aws::String > &&value)
PutBucketLifecycleConfigurationRequest & WithExpectedBucketOwner(Aws::String &&value)
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
Definition: HttpTypes.h:53
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
Definition: AWSMap.h:19
PutBucketLifecycleConfigurationRequest & WithCustomizedAccessLogTag(Aws::Map< Aws::String, Aws::String > &&value)
#define AWS_S3_API
Definition: S3_EXPORTS.h:28
const Aws::Map< Aws::String, Aws::String > & GetCustomizedAccessLogTag() const
void SetLifecycleConfiguration(const BucketLifecycleConfiguration &value)
PutBucketLifecycleConfigurationRequest & WithCustomizedAccessLogTag(const Aws::Map< Aws::String, Aws::String > &value)
PutBucketLifecycleConfigurationRequest & WithExpectedBucketOwner(const Aws::String &value)
PutBucketLifecycleConfigurationRequest & AddCustomizedAccessLogTag(Aws::String &&key, Aws::String &&value)
PutBucketLifecycleConfigurationRequest & AddCustomizedAccessLogTag(const Aws::String &key, Aws::String &&value)
PutBucketLifecycleConfigurationRequest & AddCustomizedAccessLogTag(const Aws::String &key, const Aws::String &value)
PutBucketLifecycleConfigurationRequest & AddCustomizedAccessLogTag(const char *key, const char *value)
PutBucketLifecycleConfigurationRequest & WithLifecycleConfiguration(const BucketLifecycleConfiguration &value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
void SetCustomizedAccessLogTag(const Aws::Map< Aws::String, Aws::String > &value)
PutBucketLifecycleConfigurationRequest & WithLifecycleConfiguration(BucketLifecycleConfiguration &&value)
PutBucketLifecycleConfigurationRequest & AddCustomizedAccessLogTag(Aws::String &&key, const char *value)
PutBucketLifecycleConfigurationRequest & AddCustomizedAccessLogTag(Aws::String &&key, const Aws::String &value)
PutBucketLifecycleConfigurationRequest & WithExpectedBucketOwner(const char *value)
PutBucketLifecycleConfigurationRequest & WithBucket(const char *value)
PutBucketLifecycleConfigurationRequest & WithBucket(const Aws::String &value)