AWS SDK for C++  1.9.156
AWS SDK for C++
PutRolePolicyRequest.h
Go to the documentation of this file.
1 
6 #pragma once
7 #include <aws/iam/IAM_EXPORTS.h>
8 #include <aws/iam/IAMRequest.h>
10 #include <utility>
11 
12 namespace Aws
13 {
14 namespace IAM
15 {
16 namespace Model
17 {
18 
22  {
23  public:
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 "PutRolePolicy"; }
31 
32  Aws::String SerializePayload() const override;
33 
34  protected:
35  void DumpBodyToUrl(Aws::Http::URI& uri ) const override;
36 
37  public:
38 
46  inline const Aws::String& GetRoleName() const{ return m_roleName; }
47 
55  inline bool RoleNameHasBeenSet() const { return m_roleNameHasBeenSet; }
56 
64  inline void SetRoleName(const Aws::String& value) { m_roleNameHasBeenSet = true; m_roleName = value; }
65 
73  inline void SetRoleName(Aws::String&& value) { m_roleNameHasBeenSet = true; m_roleName = std::move(value); }
74 
82  inline void SetRoleName(const char* value) { m_roleNameHasBeenSet = true; m_roleName.assign(value); }
83 
91  inline PutRolePolicyRequest& WithRoleName(const Aws::String& value) { SetRoleName(value); return *this;}
92 
100  inline PutRolePolicyRequest& WithRoleName(Aws::String&& value) { SetRoleName(std::move(value)); return *this;}
101 
109  inline PutRolePolicyRequest& WithRoleName(const char* value) { SetRoleName(value); return *this;}
110 
111 
118  inline const Aws::String& GetPolicyName() const{ return m_policyName; }
119 
126  inline bool PolicyNameHasBeenSet() const { return m_policyNameHasBeenSet; }
127 
134  inline void SetPolicyName(const Aws::String& value) { m_policyNameHasBeenSet = true; m_policyName = value; }
135 
142  inline void SetPolicyName(Aws::String&& value) { m_policyNameHasBeenSet = true; m_policyName = std::move(value); }
143 
150  inline void SetPolicyName(const char* value) { m_policyNameHasBeenSet = true; m_policyName.assign(value); }
151 
158  inline PutRolePolicyRequest& WithPolicyName(const Aws::String& value) { SetPolicyName(value); return *this;}
159 
166  inline PutRolePolicyRequest& WithPolicyName(Aws::String&& value) { SetPolicyName(std::move(value)); return *this;}
167 
174  inline PutRolePolicyRequest& WithPolicyName(const char* value) { SetPolicyName(value); return *this;}
175 
176 
191  inline const Aws::String& GetPolicyDocument() const{ return m_policyDocument; }
192 
207  inline bool PolicyDocumentHasBeenSet() const { return m_policyDocumentHasBeenSet; }
208 
223  inline void SetPolicyDocument(const Aws::String& value) { m_policyDocumentHasBeenSet = true; m_policyDocument = value; }
224 
239  inline void SetPolicyDocument(Aws::String&& value) { m_policyDocumentHasBeenSet = true; m_policyDocument = std::move(value); }
240 
255  inline void SetPolicyDocument(const char* value) { m_policyDocumentHasBeenSet = true; m_policyDocument.assign(value); }
256 
271  inline PutRolePolicyRequest& WithPolicyDocument(const Aws::String& value) { SetPolicyDocument(value); return *this;}
272 
287  inline PutRolePolicyRequest& WithPolicyDocument(Aws::String&& value) { SetPolicyDocument(std::move(value)); return *this;}
288 
303  inline PutRolePolicyRequest& WithPolicyDocument(const char* value) { SetPolicyDocument(value); return *this;}
304 
305  private:
306 
307  Aws::String m_roleName;
308  bool m_roleNameHasBeenSet;
309 
310  Aws::String m_policyName;
311  bool m_policyNameHasBeenSet;
312 
313  Aws::String m_policyDocument;
314  bool m_policyDocumentHasBeenSet;
315  };
316 
317 } // namespace Model
318 } // namespace IAM
319 } // namespace Aws
Aws::IAM::Model::PutRolePolicyRequest::GetPolicyName
const Aws::String & GetPolicyName() const
Definition: PutRolePolicyRequest.h:118
Aws::IAM::Model::PutRolePolicyRequest::PolicyDocumentHasBeenSet
bool PolicyDocumentHasBeenSet() const
Definition: PutRolePolicyRequest.h:207
Aws::Http::URI
Definition: URI.h:32
Aws::IAM::Model::PutRolePolicyRequest::WithPolicyDocument
PutRolePolicyRequest & WithPolicyDocument(Aws::String &&value)
Definition: PutRolePolicyRequest.h:287
Aws::IAM::IAMRequest
Definition: IAMRequest.h:17
Aws::IAM::Model::PutRolePolicyRequest::WithPolicyName
PutRolePolicyRequest & WithPolicyName(const Aws::String &value)
Definition: PutRolePolicyRequest.h:158
Aws::EMR::Model::AuthMode::NOT_SET
@ NOT_SET
Aws::IAM::Model::PutRolePolicyRequest::SetPolicyDocument
void SetPolicyDocument(const char *value)
Definition: PutRolePolicyRequest.h:255
Aws::IAM::Model::PutRolePolicyRequest::WithRoleName
PutRolePolicyRequest & WithRoleName(const Aws::String &value)
Definition: PutRolePolicyRequest.h:91
Aws::IAM::Model::PutRolePolicyRequest::GetRoleName
const Aws::String & GetRoleName() const
Definition: PutRolePolicyRequest.h:46
Aws::IAM::Model::PutRolePolicyRequest::WithPolicyDocument
PutRolePolicyRequest & WithPolicyDocument(const Aws::String &value)
Definition: PutRolePolicyRequest.h:271
Aws::IAM::Model::PutRolePolicyRequest::SetPolicyDocument
void SetPolicyDocument(const Aws::String &value)
Definition: PutRolePolicyRequest.h:223
Aws::IAM::Model::PutRolePolicyRequest::SerializePayload
Aws::String SerializePayload() const override
AWS_IAM_API
#define AWS_IAM_API
Definition: IAM_EXPORTS.h:28
Aws::IAM::Model::PutRolePolicyRequest::SetRoleName
void SetRoleName(const Aws::String &value)
Definition: PutRolePolicyRequest.h:64
Aws::IAM::Model::PutRolePolicyRequest::GetServiceRequestName
virtual const char * GetServiceRequestName() const override
Definition: PutRolePolicyRequest.h:30
Aws::IAM::Model::PutRolePolicyRequest
Definition: PutRolePolicyRequest.h:22
Aws::IAM::Model::PutRolePolicyRequest::WithPolicyName
PutRolePolicyRequest & WithPolicyName(const char *value)
Definition: PutRolePolicyRequest.h:174
Aws::IAM::Model::PutRolePolicyRequest::WithRoleName
PutRolePolicyRequest & WithRoleName(const char *value)
Definition: PutRolePolicyRequest.h:109
AWSString.h
Aws::IAM::Model::PutRolePolicyRequest::GetPolicyDocument
const Aws::String & GetPolicyDocument() const
Definition: PutRolePolicyRequest.h:191
Aws::IAM::Model::PutRolePolicyRequest::WithPolicyName
PutRolePolicyRequest & WithPolicyName(Aws::String &&value)
Definition: PutRolePolicyRequest.h:166
Aws::IAM::Model::PutRolePolicyRequest::SetPolicyDocument
void SetPolicyDocument(Aws::String &&value)
Definition: PutRolePolicyRequest.h:239
Aws::IAM::Model::PutRolePolicyRequest::SetPolicyName
void SetPolicyName(const Aws::String &value)
Definition: PutRolePolicyRequest.h:134
IAM_EXPORTS.h
Aws::IAM::Model::PutRolePolicyRequest::PolicyNameHasBeenSet
bool PolicyNameHasBeenSet() const
Definition: PutRolePolicyRequest.h:126
Aws::IAM::Model::PutRolePolicyRequest::WithRoleName
PutRolePolicyRequest & WithRoleName(Aws::String &&value)
Definition: PutRolePolicyRequest.h:100
IAMRequest.h
Aws::IAM::Model::PutRolePolicyRequest::PutRolePolicyRequest
PutRolePolicyRequest()
Aws
Definition: AccessManagementClient.h:15
Aws::IAM::Model::PutRolePolicyRequest::SetRoleName
void SetRoleName(Aws::String &&value)
Definition: PutRolePolicyRequest.h:73
Aws::IAM::Model::PutRolePolicyRequest::SetPolicyName
void SetPolicyName(Aws::String &&value)
Definition: PutRolePolicyRequest.h:142
Aws::String
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
Aws::IAM::Model::PutRolePolicyRequest::SetPolicyName
void SetPolicyName(const char *value)
Definition: PutRolePolicyRequest.h:150
Aws::IAM::Model::PutRolePolicyRequest::DumpBodyToUrl
void DumpBodyToUrl(Aws::Http::URI &uri) const override
Aws::IAM::Model::PutRolePolicyRequest::RoleNameHasBeenSet
bool RoleNameHasBeenSet() const
Definition: PutRolePolicyRequest.h:55
Aws::IAM::Model::PutRolePolicyRequest::WithPolicyDocument
PutRolePolicyRequest & WithPolicyDocument(const char *value)
Definition: PutRolePolicyRequest.h:303
Aws::IAM::Model::PutRolePolicyRequest::SetRoleName
void SetRoleName(const char *value)
Definition: PutRolePolicyRequest.h:82