AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
PutBucketPolicyRequest.h
1
6#pragma once
7#include <aws/s3control/S3Control_EXPORTS.h>
8#include <aws/s3control/S3ControlRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <utility>
11
12namespace Aws
13{
14namespace S3Control
15{
16namespace Model
17{
18
22 {
23 public:
24 AWS_S3CONTROL_API PutBucketPolicyRequest();
25
26 // Service request name is the Operation name which will send this request out,
27 // each operation should has unique request name, so that we can get operation's name from this request.
28 // Note: this is not true for response, multiple operations may have the same response name,
29 // so we can not get operation's name from response.
30 inline virtual const char* GetServiceRequestName() const override { return "PutBucketPolicy"; }
31
32 AWS_S3CONTROL_API Aws::String SerializePayload() const override;
33
35
36 AWS_S3CONTROL_API inline bool ShouldComputeContentMd5() const override { return true; }
37
41 AWS_S3CONTROL_API EndpointParameters GetEndpointContextParams() const override;
42
44
47 inline const Aws::String& GetAccountId() const{ return m_accountId; }
48 inline bool AccountIdHasBeenSet() const { return m_accountIdHasBeenSet; }
49 inline void SetAccountId(const Aws::String& value) { m_accountIdHasBeenSet = true; m_accountId = value; }
50 inline void SetAccountId(Aws::String&& value) { m_accountIdHasBeenSet = true; m_accountId = std::move(value); }
51 inline void SetAccountId(const char* value) { m_accountIdHasBeenSet = true; m_accountId.assign(value); }
52 inline PutBucketPolicyRequest& WithAccountId(const Aws::String& value) { SetAccountId(value); return *this;}
53 inline PutBucketPolicyRequest& WithAccountId(Aws::String&& value) { SetAccountId(std::move(value)); return *this;}
54 inline PutBucketPolicyRequest& WithAccountId(const char* value) { SetAccountId(value); return *this;}
56
58
71 inline const Aws::String& GetBucket() const{ return m_bucket; }
72 inline bool BucketHasBeenSet() const { return m_bucketHasBeenSet; }
73 inline void SetBucket(const Aws::String& value) { m_bucketHasBeenSet = true; m_bucket = value; }
74 inline void SetBucket(Aws::String&& value) { m_bucketHasBeenSet = true; m_bucket = std::move(value); }
75 inline void SetBucket(const char* value) { m_bucketHasBeenSet = true; m_bucket.assign(value); }
76 inline PutBucketPolicyRequest& WithBucket(const Aws::String& value) { SetBucket(value); return *this;}
77 inline PutBucketPolicyRequest& WithBucket(Aws::String&& value) { SetBucket(std::move(value)); return *this;}
78 inline PutBucketPolicyRequest& WithBucket(const char* value) { SetBucket(value); return *this;}
80
82
87 inline bool GetConfirmRemoveSelfBucketAccess() const{ return m_confirmRemoveSelfBucketAccess; }
88 inline bool ConfirmRemoveSelfBucketAccessHasBeenSet() const { return m_confirmRemoveSelfBucketAccessHasBeenSet; }
89 inline void SetConfirmRemoveSelfBucketAccess(bool value) { m_confirmRemoveSelfBucketAccessHasBeenSet = true; m_confirmRemoveSelfBucketAccess = value; }
92
94
97 inline const Aws::String& GetPolicy() const{ return m_policy; }
98 inline bool PolicyHasBeenSet() const { return m_policyHasBeenSet; }
99 inline void SetPolicy(const Aws::String& value) { m_policyHasBeenSet = true; m_policy = value; }
100 inline void SetPolicy(Aws::String&& value) { m_policyHasBeenSet = true; m_policy = std::move(value); }
101 inline void SetPolicy(const char* value) { m_policyHasBeenSet = true; m_policy.assign(value); }
102 inline PutBucketPolicyRequest& WithPolicy(const Aws::String& value) { SetPolicy(value); return *this;}
103 inline PutBucketPolicyRequest& WithPolicy(Aws::String&& value) { SetPolicy(std::move(value)); return *this;}
104 inline PutBucketPolicyRequest& WithPolicy(const char* value) { SetPolicy(value); return *this;}
106 private:
107
108 Aws::String m_accountId;
109 bool m_accountIdHasBeenSet = false;
110
111 Aws::String m_bucket;
112 bool m_bucketHasBeenSet = false;
113
114 bool m_confirmRemoveSelfBucketAccess;
115 bool m_confirmRemoveSelfBucketAccessHasBeenSet = false;
116
117 Aws::String m_policy;
118 bool m_policyHasBeenSet = false;
119 };
120
121} // namespace Model
122} // namespace S3Control
123} // namespace Aws
PutBucketPolicyRequest & WithBucket(Aws::String &&value)
PutBucketPolicyRequest & WithConfirmRemoveSelfBucketAccess(bool value)
PutBucketPolicyRequest & WithPolicy(const Aws::String &value)
PutBucketPolicyRequest & WithAccountId(const char *value)
PutBucketPolicyRequest & WithAccountId(Aws::String &&value)
virtual const char * GetServiceRequestName() const override
PutBucketPolicyRequest & WithBucket(const char *value)
PutBucketPolicyRequest & WithPolicy(Aws::String &&value)
AWS_S3CONTROL_API Aws::String SerializePayload() const override
AWS_S3CONTROL_API bool ShouldComputeContentMd5() const override
PutBucketPolicyRequest & WithAccountId(const Aws::String &value)
PutBucketPolicyRequest & WithPolicy(const char *value)
AWS_S3CONTROL_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
AWS_S3CONTROL_API EndpointParameters GetEndpointContextParams() const override
PutBucketPolicyRequest & WithBucket(const Aws::String &value)
Aws::Endpoint::EndpointParameters EndpointParameters
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String