AWS SDK for C++  1.9.40
AWS SDK for C++
PutUserPolicyRequest.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 "PutUserPolicy"; }
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& GetUserName() const{ return m_userName; }
47 
55  inline bool UserNameHasBeenSet() const { return m_userNameHasBeenSet; }
56 
64  inline void SetUserName(const Aws::String& value) { m_userNameHasBeenSet = true; m_userName = value; }
65 
73  inline void SetUserName(Aws::String&& value) { m_userNameHasBeenSet = true; m_userName = std::move(value); }
74 
82  inline void SetUserName(const char* value) { m_userNameHasBeenSet = true; m_userName.assign(value); }
83 
91  inline PutUserPolicyRequest& WithUserName(const Aws::String& value) { SetUserName(value); return *this;}
92 
100  inline PutUserPolicyRequest& WithUserName(Aws::String&& value) { SetUserName(std::move(value)); return *this;}
101 
109  inline PutUserPolicyRequest& WithUserName(const char* value) { SetUserName(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 PutUserPolicyRequest& WithPolicyName(const Aws::String& value) { SetPolicyName(value); return *this;}
159 
166  inline PutUserPolicyRequest& WithPolicyName(Aws::String&& value) { SetPolicyName(std::move(value)); return *this;}
167 
174  inline PutUserPolicyRequest& 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 PutUserPolicyRequest& WithPolicyDocument(const Aws::String& value) { SetPolicyDocument(value); return *this;}
272 
287  inline PutUserPolicyRequest& WithPolicyDocument(Aws::String&& value) { SetPolicyDocument(std::move(value)); return *this;}
288 
303  inline PutUserPolicyRequest& WithPolicyDocument(const char* value) { SetPolicyDocument(value); return *this;}
304 
305  private:
306 
307  Aws::String m_userName;
308  bool m_userNameHasBeenSet;
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::PutUserPolicyRequest::GetServiceRequestName
virtual const char * GetServiceRequestName() const override
Definition: PutUserPolicyRequest.h:30
Aws::IAM::Model::PutUserPolicyRequest::WithUserName
PutUserPolicyRequest & WithUserName(const char *value)
Definition: PutUserPolicyRequest.h:109
Aws::IAM::Model::PutUserPolicyRequest::SetUserName
void SetUserName(Aws::String &&value)
Definition: PutUserPolicyRequest.h:73
Aws::Http::URI
Definition: URI.h:32
Aws::IAM::Model::PutUserPolicyRequest::DumpBodyToUrl
void DumpBodyToUrl(Aws::Http::URI &uri) const override
Aws::IAM::Model::PutUserPolicyRequest::WithPolicyName
PutUserPolicyRequest & WithPolicyName(const Aws::String &value)
Definition: PutUserPolicyRequest.h:158
Aws::IAM::Model::PutUserPolicyRequest::SetPolicyDocument
void SetPolicyDocument(const Aws::String &value)
Definition: PutUserPolicyRequest.h:223
Aws::IAM::Model::PutUserPolicyRequest::SerializePayload
Aws::String SerializePayload() const override
Aws::IAM::IAMRequest
Definition: IAMRequest.h:17
Aws::EMR::Model::AuthMode::NOT_SET
@ NOT_SET
Aws::IAM::Model::PutUserPolicyRequest::SetPolicyName
void SetPolicyName(const char *value)
Definition: PutUserPolicyRequest.h:150
Aws::IAM::Model::PutUserPolicyRequest::SetUserName
void SetUserName(const Aws::String &value)
Definition: PutUserPolicyRequest.h:64
Aws::IAM::Model::PutUserPolicyRequest::WithPolicyDocument
PutUserPolicyRequest & WithPolicyDocument(Aws::String &&value)
Definition: PutUserPolicyRequest.h:287
Aws::IAM::Model::PutUserPolicyRequest::SetUserName
void SetUserName(const char *value)
Definition: PutUserPolicyRequest.h:82
Aws::IAM::Model::PutUserPolicyRequest::WithUserName
PutUserPolicyRequest & WithUserName(Aws::String &&value)
Definition: PutUserPolicyRequest.h:100
AWS_IAM_API
#define AWS_IAM_API
Definition: IAM_EXPORTS.h:28
Aws::IAM::Model::PutUserPolicyRequest::WithPolicyName
PutUserPolicyRequest & WithPolicyName(const char *value)
Definition: PutUserPolicyRequest.h:174
Aws::IAM::Model::PutUserPolicyRequest::UserNameHasBeenSet
bool UserNameHasBeenSet() const
Definition: PutUserPolicyRequest.h:55
Aws::IAM::Model::PutUserPolicyRequest::SetPolicyDocument
void SetPolicyDocument(const char *value)
Definition: PutUserPolicyRequest.h:255
Aws::IAM::Model::PutUserPolicyRequest::PutUserPolicyRequest
PutUserPolicyRequest()
AWSString.h
Aws::IAM::Model::PutUserPolicyRequest::GetUserName
const Aws::String & GetUserName() const
Definition: PutUserPolicyRequest.h:46
Aws::IAM::Model::PutUserPolicyRequest::WithPolicyName
PutUserPolicyRequest & WithPolicyName(Aws::String &&value)
Definition: PutUserPolicyRequest.h:166
Aws::IAM::Model::PutUserPolicyRequest::PolicyDocumentHasBeenSet
bool PolicyDocumentHasBeenSet() const
Definition: PutUserPolicyRequest.h:207
Aws::IAM::Model::PutUserPolicyRequest::WithPolicyDocument
PutUserPolicyRequest & WithPolicyDocument(const char *value)
Definition: PutUserPolicyRequest.h:303
Aws::IAM::Model::PutUserPolicyRequest::GetPolicyName
const Aws::String & GetPolicyName() const
Definition: PutUserPolicyRequest.h:118
IAM_EXPORTS.h
Aws::IAM::Model::PutUserPolicyRequest::SetPolicyDocument
void SetPolicyDocument(Aws::String &&value)
Definition: PutUserPolicyRequest.h:239
Aws::IAM::Model::PutUserPolicyRequest::GetPolicyDocument
const Aws::String & GetPolicyDocument() const
Definition: PutUserPolicyRequest.h:191
IAMRequest.h
Aws
Definition: AccessManagementClient.h:15
Aws::IAM::Model::PutUserPolicyRequest::SetPolicyName
void SetPolicyName(Aws::String &&value)
Definition: PutUserPolicyRequest.h:142
Aws::IAM::Model::PutUserPolicyRequest::SetPolicyName
void SetPolicyName(const Aws::String &value)
Definition: PutUserPolicyRequest.h:134
Aws::String
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
Aws::IAM::Model::PutUserPolicyRequest::WithUserName
PutUserPolicyRequest & WithUserName(const Aws::String &value)
Definition: PutUserPolicyRequest.h:91
Aws::IAM::Model::PutUserPolicyRequest
Definition: PutUserPolicyRequest.h:22
Aws::IAM::Model::PutUserPolicyRequest::WithPolicyDocument
PutUserPolicyRequest & WithPolicyDocument(const Aws::String &value)
Definition: PutUserPolicyRequest.h:271
Aws::IAM::Model::PutUserPolicyRequest::PolicyNameHasBeenSet
bool PolicyNameHasBeenSet() const
Definition: PutUserPolicyRequest.h:126