AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
Credentials.h
1
6#pragma once
7#include <aws/cognito-identity/CognitoIdentity_EXPORTS.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/DateTime.h>
10#include <utility>
11
12namespace Aws
13{
14namespace Utils
15{
16namespace Json
17{
18 class JsonValue;
19 class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace CognitoIdentity
23{
24namespace Model
25{
26
33 {
34 public:
35 AWS_COGNITOIDENTITY_API Credentials();
36 AWS_COGNITOIDENTITY_API Credentials(Aws::Utils::Json::JsonView jsonValue);
37 AWS_COGNITOIDENTITY_API Credentials& operator=(Aws::Utils::Json::JsonView jsonValue);
38 AWS_COGNITOIDENTITY_API Aws::Utils::Json::JsonValue Jsonize() const;
39
40
42
45 inline const Aws::String& GetAccessKeyId() const{ return m_accessKeyId; }
46 inline bool AccessKeyIdHasBeenSet() const { return m_accessKeyIdHasBeenSet; }
47 inline void SetAccessKeyId(const Aws::String& value) { m_accessKeyIdHasBeenSet = true; m_accessKeyId = value; }
48 inline void SetAccessKeyId(Aws::String&& value) { m_accessKeyIdHasBeenSet = true; m_accessKeyId = std::move(value); }
49 inline void SetAccessKeyId(const char* value) { m_accessKeyIdHasBeenSet = true; m_accessKeyId.assign(value); }
50 inline Credentials& WithAccessKeyId(const Aws::String& value) { SetAccessKeyId(value); return *this;}
51 inline Credentials& WithAccessKeyId(Aws::String&& value) { SetAccessKeyId(std::move(value)); return *this;}
52 inline Credentials& WithAccessKeyId(const char* value) { SetAccessKeyId(value); return *this;}
54
56
59 inline const Aws::String& GetSecretKey() const{ return m_secretKey; }
60 inline bool SecretKeyHasBeenSet() const { return m_secretKeyHasBeenSet; }
61 inline void SetSecretKey(const Aws::String& value) { m_secretKeyHasBeenSet = true; m_secretKey = value; }
62 inline void SetSecretKey(Aws::String&& value) { m_secretKeyHasBeenSet = true; m_secretKey = std::move(value); }
63 inline void SetSecretKey(const char* value) { m_secretKeyHasBeenSet = true; m_secretKey.assign(value); }
64 inline Credentials& WithSecretKey(const Aws::String& value) { SetSecretKey(value); return *this;}
65 inline Credentials& WithSecretKey(Aws::String&& value) { SetSecretKey(std::move(value)); return *this;}
66 inline Credentials& WithSecretKey(const char* value) { SetSecretKey(value); return *this;}
68
70
73 inline const Aws::String& GetSessionToken() const{ return m_sessionToken; }
74 inline bool SessionTokenHasBeenSet() const { return m_sessionTokenHasBeenSet; }
75 inline void SetSessionToken(const Aws::String& value) { m_sessionTokenHasBeenSet = true; m_sessionToken = value; }
76 inline void SetSessionToken(Aws::String&& value) { m_sessionTokenHasBeenSet = true; m_sessionToken = std::move(value); }
77 inline void SetSessionToken(const char* value) { m_sessionTokenHasBeenSet = true; m_sessionToken.assign(value); }
78 inline Credentials& WithSessionToken(const Aws::String& value) { SetSessionToken(value); return *this;}
79 inline Credentials& WithSessionToken(Aws::String&& value) { SetSessionToken(std::move(value)); return *this;}
80 inline Credentials& WithSessionToken(const char* value) { SetSessionToken(value); return *this;}
82
84
87 inline const Aws::Utils::DateTime& GetExpiration() const{ return m_expiration; }
88 inline bool ExpirationHasBeenSet() const { return m_expirationHasBeenSet; }
89 inline void SetExpiration(const Aws::Utils::DateTime& value) { m_expirationHasBeenSet = true; m_expiration = value; }
90 inline void SetExpiration(Aws::Utils::DateTime&& value) { m_expirationHasBeenSet = true; m_expiration = std::move(value); }
91 inline Credentials& WithExpiration(const Aws::Utils::DateTime& value) { SetExpiration(value); return *this;}
92 inline Credentials& WithExpiration(Aws::Utils::DateTime&& value) { SetExpiration(std::move(value)); return *this;}
94 private:
95
96 Aws::String m_accessKeyId;
97 bool m_accessKeyIdHasBeenSet = false;
98
99 Aws::String m_secretKey;
100 bool m_secretKeyHasBeenSet = false;
101
102 Aws::String m_sessionToken;
103 bool m_sessionTokenHasBeenSet = false;
104
105 Aws::Utils::DateTime m_expiration;
106 bool m_expirationHasBeenSet = false;
107 };
108
109} // namespace Model
110} // namespace CognitoIdentity
111} // namespace Aws
void SetSessionToken(const Aws::String &value)
Definition Credentials.h:75
Credentials & WithSecretKey(Aws::String &&value)
Definition Credentials.h:65
Credentials & WithSecretKey(const Aws::String &value)
Definition Credentials.h:64
Credentials & WithSecretKey(const char *value)
Definition Credentials.h:66
AWS_COGNITOIDENTITY_API Credentials & operator=(Aws::Utils::Json::JsonView jsonValue)
Credentials & WithExpiration(const Aws::Utils::DateTime &value)
Definition Credentials.h:91
void SetSecretKey(Aws::String &&value)
Definition Credentials.h:62
const Aws::String & GetAccessKeyId() const
Definition Credentials.h:45
Credentials & WithAccessKeyId(const Aws::String &value)
Definition Credentials.h:50
const Aws::String & GetSessionToken() const
Definition Credentials.h:73
Credentials & WithSessionToken(const Aws::String &value)
Definition Credentials.h:78
void SetSessionToken(const char *value)
Definition Credentials.h:77
Credentials & WithSessionToken(const char *value)
Definition Credentials.h:80
void SetAccessKeyId(Aws::String &&value)
Definition Credentials.h:48
void SetSecretKey(const Aws::String &value)
Definition Credentials.h:61
const Aws::Utils::DateTime & GetExpiration() const
Definition Credentials.h:87
Credentials & WithExpiration(Aws::Utils::DateTime &&value)
Definition Credentials.h:92
void SetSessionToken(Aws::String &&value)
Definition Credentials.h:76
void SetSecretKey(const char *value)
Definition Credentials.h:63
void SetAccessKeyId(const Aws::String &value)
Definition Credentials.h:47
Credentials & WithAccessKeyId(Aws::String &&value)
Definition Credentials.h:51
void SetExpiration(Aws::Utils::DateTime &&value)
Definition Credentials.h:90
Credentials & WithSessionToken(Aws::String &&value)
Definition Credentials.h:79
const Aws::String & GetSecretKey() const
Definition Credentials.h:59
Credentials & WithAccessKeyId(const char *value)
Definition Credentials.h:52
AWS_COGNITOIDENTITY_API Credentials()
void SetExpiration(const Aws::Utils::DateTime &value)
Definition Credentials.h:89
AWS_COGNITOIDENTITY_API Aws::Utils::Json::JsonValue Jsonize() const
void SetAccessKeyId(const char *value)
Definition Credentials.h:49
AWS_COGNITOIDENTITY_API Credentials(Aws::Utils::Json::JsonView jsonValue)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue