AWS SDK for C++  1.9.159
AWS SDK for C++
EnableMFADeviceRequest.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 "EnableMFADevice"; }
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 EnableMFADeviceRequest& WithUserName(const Aws::String& value) { SetUserName(value); return *this;}
92 
100  inline EnableMFADeviceRequest& WithUserName(Aws::String&& value) { SetUserName(std::move(value)); return *this;}
101 
109  inline EnableMFADeviceRequest& WithUserName(const char* value) { SetUserName(value); return *this;}
110 
111 
120  inline const Aws::String& GetSerialNumber() const{ return m_serialNumber; }
121 
130  inline bool SerialNumberHasBeenSet() const { return m_serialNumberHasBeenSet; }
131 
140  inline void SetSerialNumber(const Aws::String& value) { m_serialNumberHasBeenSet = true; m_serialNumber = value; }
141 
150  inline void SetSerialNumber(Aws::String&& value) { m_serialNumberHasBeenSet = true; m_serialNumber = std::move(value); }
151 
160  inline void SetSerialNumber(const char* value) { m_serialNumberHasBeenSet = true; m_serialNumber.assign(value); }
161 
170  inline EnableMFADeviceRequest& WithSerialNumber(const Aws::String& value) { SetSerialNumber(value); return *this;}
171 
180  inline EnableMFADeviceRequest& WithSerialNumber(Aws::String&& value) { SetSerialNumber(std::move(value)); return *this;}
181 
190  inline EnableMFADeviceRequest& WithSerialNumber(const char* value) { SetSerialNumber(value); return *this;}
191 
192 
204  inline const Aws::String& GetAuthenticationCode1() const{ return m_authenticationCode1; }
205 
217  inline bool AuthenticationCode1HasBeenSet() const { return m_authenticationCode1HasBeenSet; }
218 
230  inline void SetAuthenticationCode1(const Aws::String& value) { m_authenticationCode1HasBeenSet = true; m_authenticationCode1 = value; }
231 
243  inline void SetAuthenticationCode1(Aws::String&& value) { m_authenticationCode1HasBeenSet = true; m_authenticationCode1 = std::move(value); }
244 
256  inline void SetAuthenticationCode1(const char* value) { m_authenticationCode1HasBeenSet = true; m_authenticationCode1.assign(value); }
257 
269  inline EnableMFADeviceRequest& WithAuthenticationCode1(const Aws::String& value) { SetAuthenticationCode1(value); return *this;}
270 
282  inline EnableMFADeviceRequest& WithAuthenticationCode1(Aws::String&& value) { SetAuthenticationCode1(std::move(value)); return *this;}
283 
295  inline EnableMFADeviceRequest& WithAuthenticationCode1(const char* value) { SetAuthenticationCode1(value); return *this;}
296 
297 
309  inline const Aws::String& GetAuthenticationCode2() const{ return m_authenticationCode2; }
310 
322  inline bool AuthenticationCode2HasBeenSet() const { return m_authenticationCode2HasBeenSet; }
323 
335  inline void SetAuthenticationCode2(const Aws::String& value) { m_authenticationCode2HasBeenSet = true; m_authenticationCode2 = value; }
336 
348  inline void SetAuthenticationCode2(Aws::String&& value) { m_authenticationCode2HasBeenSet = true; m_authenticationCode2 = std::move(value); }
349 
361  inline void SetAuthenticationCode2(const char* value) { m_authenticationCode2HasBeenSet = true; m_authenticationCode2.assign(value); }
362 
374  inline EnableMFADeviceRequest& WithAuthenticationCode2(const Aws::String& value) { SetAuthenticationCode2(value); return *this;}
375 
387  inline EnableMFADeviceRequest& WithAuthenticationCode2(Aws::String&& value) { SetAuthenticationCode2(std::move(value)); return *this;}
388 
400  inline EnableMFADeviceRequest& WithAuthenticationCode2(const char* value) { SetAuthenticationCode2(value); return *this;}
401 
402  private:
403 
404  Aws::String m_userName;
405  bool m_userNameHasBeenSet;
406 
407  Aws::String m_serialNumber;
408  bool m_serialNumberHasBeenSet;
409 
410  Aws::String m_authenticationCode1;
411  bool m_authenticationCode1HasBeenSet;
412 
413  Aws::String m_authenticationCode2;
414  bool m_authenticationCode2HasBeenSet;
415  };
416 
417 } // namespace Model
418 } // namespace IAM
419 } // namespace Aws
Aws::IAM::Model::EnableMFADeviceRequest::WithAuthenticationCode2
EnableMFADeviceRequest & WithAuthenticationCode2(const char *value)
Definition: EnableMFADeviceRequest.h:400
Aws::IAM::Model::EnableMFADeviceRequest::UserNameHasBeenSet
bool UserNameHasBeenSet() const
Definition: EnableMFADeviceRequest.h:55
Aws::IAM::Model::EnableMFADeviceRequest::WithUserName
EnableMFADeviceRequest & WithUserName(const Aws::String &value)
Definition: EnableMFADeviceRequest.h:91
Aws::IAM::Model::EnableMFADeviceRequest::SetAuthenticationCode1
void SetAuthenticationCode1(const char *value)
Definition: EnableMFADeviceRequest.h:256
Aws::Http::URI
Definition: URI.h:32
Aws::IAM::Model::EnableMFADeviceRequest::WithSerialNumber
EnableMFADeviceRequest & WithSerialNumber(const Aws::String &value)
Definition: EnableMFADeviceRequest.h:170
Aws::IAM::Model::EnableMFADeviceRequest::SetAuthenticationCode2
void SetAuthenticationCode2(const Aws::String &value)
Definition: EnableMFADeviceRequest.h:335
Aws::IAM::Model::EnableMFADeviceRequest::SetUserName
void SetUserName(Aws::String &&value)
Definition: EnableMFADeviceRequest.h:73
Aws::IAM::Model::EnableMFADeviceRequest::GetAuthenticationCode1
const Aws::String & GetAuthenticationCode1() const
Definition: EnableMFADeviceRequest.h:204
Aws::IAM::Model::EnableMFADeviceRequest::WithSerialNumber
EnableMFADeviceRequest & WithSerialNumber(const char *value)
Definition: EnableMFADeviceRequest.h:190
Aws::IAM::Model::EnableMFADeviceRequest::SetUserName
void SetUserName(const char *value)
Definition: EnableMFADeviceRequest.h:82
Aws::IAM::IAMRequest
Definition: IAMRequest.h:17
Aws::IAM::Model::EnableMFADeviceRequest::AuthenticationCode1HasBeenSet
bool AuthenticationCode1HasBeenSet() const
Definition: EnableMFADeviceRequest.h:217
Aws::IAM::Model::EnableMFADeviceRequest::SerialNumberHasBeenSet
bool SerialNumberHasBeenSet() const
Definition: EnableMFADeviceRequest.h:130
Aws::IAM::Model::EnableMFADeviceRequest::WithAuthenticationCode1
EnableMFADeviceRequest & WithAuthenticationCode1(const char *value)
Definition: EnableMFADeviceRequest.h:295
Aws::EMR::Model::AuthMode::NOT_SET
@ NOT_SET
Aws::IAM::Model::EnableMFADeviceRequest::WithUserName
EnableMFADeviceRequest & WithUserName(Aws::String &&value)
Definition: EnableMFADeviceRequest.h:100
Aws::IAM::Model::EnableMFADeviceRequest::EnableMFADeviceRequest
EnableMFADeviceRequest()
Aws::IAM::Model::EnableMFADeviceRequest::WithUserName
EnableMFADeviceRequest & WithUserName(const char *value)
Definition: EnableMFADeviceRequest.h:109
Aws::IAM::Model::EnableMFADeviceRequest::SetAuthenticationCode1
void SetAuthenticationCode1(Aws::String &&value)
Definition: EnableMFADeviceRequest.h:243
Aws::IAM::Model::EnableMFADeviceRequest::SetAuthenticationCode2
void SetAuthenticationCode2(Aws::String &&value)
Definition: EnableMFADeviceRequest.h:348
AWS_IAM_API
#define AWS_IAM_API
Definition: IAM_EXPORTS.h:28
Aws::IAM::Model::EnableMFADeviceRequest::WithSerialNumber
EnableMFADeviceRequest & WithSerialNumber(Aws::String &&value)
Definition: EnableMFADeviceRequest.h:180
Aws::IAM::Model::EnableMFADeviceRequest::GetAuthenticationCode2
const Aws::String & GetAuthenticationCode2() const
Definition: EnableMFADeviceRequest.h:309
Aws::IAM::Model::EnableMFADeviceRequest::WithAuthenticationCode2
EnableMFADeviceRequest & WithAuthenticationCode2(const Aws::String &value)
Definition: EnableMFADeviceRequest.h:374
Aws::IAM::Model::EnableMFADeviceRequest::SetSerialNumber
void SetSerialNumber(Aws::String &&value)
Definition: EnableMFADeviceRequest.h:150
Aws::IAM::Model::EnableMFADeviceRequest::WithAuthenticationCode1
EnableMFADeviceRequest & WithAuthenticationCode1(const Aws::String &value)
Definition: EnableMFADeviceRequest.h:269
Aws::IAM::Model::EnableMFADeviceRequest::SetAuthenticationCode2
void SetAuthenticationCode2(const char *value)
Definition: EnableMFADeviceRequest.h:361
AWSString.h
Aws::IAM::Model::EnableMFADeviceRequest::DumpBodyToUrl
void DumpBodyToUrl(Aws::Http::URI &uri) const override
Aws::IAM::Model::EnableMFADeviceRequest::GetUserName
const Aws::String & GetUserName() const
Definition: EnableMFADeviceRequest.h:46
Aws::IAM::Model::EnableMFADeviceRequest::GetServiceRequestName
virtual const char * GetServiceRequestName() const override
Definition: EnableMFADeviceRequest.h:30
Aws::IAM::Model::EnableMFADeviceRequest::SetUserName
void SetUserName(const Aws::String &value)
Definition: EnableMFADeviceRequest.h:64
Aws::IAM::Model::EnableMFADeviceRequest::WithAuthenticationCode2
EnableMFADeviceRequest & WithAuthenticationCode2(Aws::String &&value)
Definition: EnableMFADeviceRequest.h:387
Aws::IAM::Model::EnableMFADeviceRequest
Definition: EnableMFADeviceRequest.h:22
IAM_EXPORTS.h
IAMRequest.h
Aws
Definition: AccessManagementClient.h:15
Aws::IAM::Model::EnableMFADeviceRequest::AuthenticationCode2HasBeenSet
bool AuthenticationCode2HasBeenSet() const
Definition: EnableMFADeviceRequest.h:322
Aws::IAM::Model::EnableMFADeviceRequest::WithAuthenticationCode1
EnableMFADeviceRequest & WithAuthenticationCode1(Aws::String &&value)
Definition: EnableMFADeviceRequest.h:282
Aws::IAM::Model::EnableMFADeviceRequest::SerializePayload
Aws::String SerializePayload() const override
Aws::IAM::Model::EnableMFADeviceRequest::SetAuthenticationCode1
void SetAuthenticationCode1(const Aws::String &value)
Definition: EnableMFADeviceRequest.h:230
Aws::String
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
Aws::IAM::Model::EnableMFADeviceRequest::GetSerialNumber
const Aws::String & GetSerialNumber() const
Definition: EnableMFADeviceRequest.h:120
Aws::IAM::Model::EnableMFADeviceRequest::SetSerialNumber
void SetSerialNumber(const Aws::String &value)
Definition: EnableMFADeviceRequest.h:140
Aws::IAM::Model::EnableMFADeviceRequest::SetSerialNumber
void SetSerialNumber(const char *value)
Definition: EnableMFADeviceRequest.h:160