AWS SDK for C++

AWS SDK for C++ Version 1.11.751

Loading...
Searching...
No Matches
TestAuthorizationRequest.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/core/utils/memory/stl/AWSVector.h>
9#include <aws/iot/IoTRequest.h>
10#include <aws/iot/IoT_EXPORTS.h>
11#include <aws/iot/model/AuthInfo.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Http {
17class URI;
18} // namespace Http
19namespace IoT {
20namespace Model {
21
25 public:
26 AWS_IOT_API TestAuthorizationRequest() = default;
27
28 // Service request name is the Operation name which will send this request out,
29 // each operation should has unique request name, so that we can get operation's name from this request.
30 // Note: this is not true for response, multiple operations may have the same response name,
31 // so we can not get operation's name from response.
32 inline virtual const char* GetServiceRequestName() const override { return "TestAuthorization"; }
33
34 AWS_IOT_API Aws::String SerializePayload() const override;
35
36 AWS_IOT_API void AddQueryStringParameters(Aws::Http::URI& uri) const override;
37
39
44 inline const Aws::String& GetPrincipal() const { return m_principal; }
45 inline bool PrincipalHasBeenSet() const { return m_principalHasBeenSet; }
46 template <typename PrincipalT = Aws::String>
47 void SetPrincipal(PrincipalT&& value) {
48 m_principalHasBeenSet = true;
49 m_principal = std::forward<PrincipalT>(value);
50 }
51 template <typename PrincipalT = Aws::String>
53 SetPrincipal(std::forward<PrincipalT>(value));
54 return *this;
55 }
57
59
62 inline const Aws::String& GetCognitoIdentityPoolId() const { return m_cognitoIdentityPoolId; }
63 inline bool CognitoIdentityPoolIdHasBeenSet() const { return m_cognitoIdentityPoolIdHasBeenSet; }
64 template <typename CognitoIdentityPoolIdT = Aws::String>
65 void SetCognitoIdentityPoolId(CognitoIdentityPoolIdT&& value) {
66 m_cognitoIdentityPoolIdHasBeenSet = true;
67 m_cognitoIdentityPoolId = std::forward<CognitoIdentityPoolIdT>(value);
68 }
69 template <typename CognitoIdentityPoolIdT = Aws::String>
70 TestAuthorizationRequest& WithCognitoIdentityPoolId(CognitoIdentityPoolIdT&& value) {
71 SetCognitoIdentityPoolId(std::forward<CognitoIdentityPoolIdT>(value));
72 return *this;
73 }
75
77
81 inline const Aws::Vector<AuthInfo>& GetAuthInfos() const { return m_authInfos; }
82 inline bool AuthInfosHasBeenSet() const { return m_authInfosHasBeenSet; }
83 template <typename AuthInfosT = Aws::Vector<AuthInfo>>
84 void SetAuthInfos(AuthInfosT&& value) {
85 m_authInfosHasBeenSet = true;
86 m_authInfos = std::forward<AuthInfosT>(value);
87 }
88 template <typename AuthInfosT = Aws::Vector<AuthInfo>>
90 SetAuthInfos(std::forward<AuthInfosT>(value));
91 return *this;
92 }
93 template <typename AuthInfosT = AuthInfo>
95 m_authInfosHasBeenSet = true;
96 m_authInfos.emplace_back(std::forward<AuthInfosT>(value));
97 return *this;
98 }
100
102
105 inline const Aws::String& GetClientId() const { return m_clientId; }
106 inline bool ClientIdHasBeenSet() const { return m_clientIdHasBeenSet; }
107 template <typename ClientIdT = Aws::String>
108 void SetClientId(ClientIdT&& value) {
109 m_clientIdHasBeenSet = true;
110 m_clientId = std::forward<ClientIdT>(value);
111 }
112 template <typename ClientIdT = Aws::String>
114 SetClientId(std::forward<ClientIdT>(value));
115 return *this;
116 }
118
120
124 inline const Aws::Vector<Aws::String>& GetPolicyNamesToAdd() const { return m_policyNamesToAdd; }
125 inline bool PolicyNamesToAddHasBeenSet() const { return m_policyNamesToAddHasBeenSet; }
126 template <typename PolicyNamesToAddT = Aws::Vector<Aws::String>>
127 void SetPolicyNamesToAdd(PolicyNamesToAddT&& value) {
128 m_policyNamesToAddHasBeenSet = true;
129 m_policyNamesToAdd = std::forward<PolicyNamesToAddT>(value);
130 }
131 template <typename PolicyNamesToAddT = Aws::Vector<Aws::String>>
132 TestAuthorizationRequest& WithPolicyNamesToAdd(PolicyNamesToAddT&& value) {
133 SetPolicyNamesToAdd(std::forward<PolicyNamesToAddT>(value));
134 return *this;
135 }
136 template <typename PolicyNamesToAddT = Aws::String>
137 TestAuthorizationRequest& AddPolicyNamesToAdd(PolicyNamesToAddT&& value) {
138 m_policyNamesToAddHasBeenSet = true;
139 m_policyNamesToAdd.emplace_back(std::forward<PolicyNamesToAddT>(value));
140 return *this;
141 }
143
145
149 inline const Aws::Vector<Aws::String>& GetPolicyNamesToSkip() const { return m_policyNamesToSkip; }
150 inline bool PolicyNamesToSkipHasBeenSet() const { return m_policyNamesToSkipHasBeenSet; }
151 template <typename PolicyNamesToSkipT = Aws::Vector<Aws::String>>
152 void SetPolicyNamesToSkip(PolicyNamesToSkipT&& value) {
153 m_policyNamesToSkipHasBeenSet = true;
154 m_policyNamesToSkip = std::forward<PolicyNamesToSkipT>(value);
155 }
156 template <typename PolicyNamesToSkipT = Aws::Vector<Aws::String>>
157 TestAuthorizationRequest& WithPolicyNamesToSkip(PolicyNamesToSkipT&& value) {
158 SetPolicyNamesToSkip(std::forward<PolicyNamesToSkipT>(value));
159 return *this;
160 }
161 template <typename PolicyNamesToSkipT = Aws::String>
162 TestAuthorizationRequest& AddPolicyNamesToSkip(PolicyNamesToSkipT&& value) {
163 m_policyNamesToSkipHasBeenSet = true;
164 m_policyNamesToSkip.emplace_back(std::forward<PolicyNamesToSkipT>(value));
165 return *this;
166 }
168 private:
169 Aws::String m_principal;
170
171 Aws::String m_cognitoIdentityPoolId;
172
173 Aws::Vector<AuthInfo> m_authInfos;
174
175 Aws::String m_clientId;
176
177 Aws::Vector<Aws::String> m_policyNamesToAdd;
178
179 Aws::Vector<Aws::String> m_policyNamesToSkip;
180 bool m_principalHasBeenSet = false;
181 bool m_cognitoIdentityPoolIdHasBeenSet = false;
182 bool m_authInfosHasBeenSet = false;
183 bool m_clientIdHasBeenSet = false;
184 bool m_policyNamesToAddHasBeenSet = false;
185 bool m_policyNamesToSkipHasBeenSet = false;
186};
187
188} // namespace Model
189} // namespace IoT
190} // namespace Aws
void SetPolicyNamesToSkip(PolicyNamesToSkipT &&value)
TestAuthorizationRequest & WithPolicyNamesToSkip(PolicyNamesToSkipT &&value)
virtual const char * GetServiceRequestName() const override
TestAuthorizationRequest & WithAuthInfos(AuthInfosT &&value)
TestAuthorizationRequest & WithPolicyNamesToAdd(PolicyNamesToAddT &&value)
const Aws::Vector< AuthInfo > & GetAuthInfos() const
TestAuthorizationRequest & WithCognitoIdentityPoolId(CognitoIdentityPoolIdT &&value)
TestAuthorizationRequest & AddPolicyNamesToSkip(PolicyNamesToSkipT &&value)
const Aws::Vector< Aws::String > & GetPolicyNamesToSkip() const
TestAuthorizationRequest & WithClientId(ClientIdT &&value)
AWS_IOT_API TestAuthorizationRequest()=default
AWS_IOT_API Aws::String SerializePayload() const override
TestAuthorizationRequest & WithPrincipal(PrincipalT &&value)
TestAuthorizationRequest & AddPolicyNamesToAdd(PolicyNamesToAddT &&value)
const Aws::Vector< Aws::String > & GetPolicyNamesToAdd() const
TestAuthorizationRequest & AddAuthInfos(AuthInfosT &&value)
void SetCognitoIdentityPoolId(CognitoIdentityPoolIdT &&value)
void SetPolicyNamesToAdd(PolicyNamesToAddT &&value)
AWS_IOT_API void AddQueryStringParameters(Aws::Http::URI &uri) const override
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector