AWS SDK for C++

AWS SDK for C++ Version 1.11.695

Loading...
Searching...
No Matches
AddPermissionRequest.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/lambda/LambdaRequest.h>
9#include <aws/lambda/Lambda_EXPORTS.h>
10#include <aws/lambda/model/FunctionUrlAuthType.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Http {
16class URI;
17} // namespace Http
18namespace Lambda {
19namespace Model {
20
24 public:
25 AWS_LAMBDA_API AddPermissionRequest() = default;
26
27 // Service request name is the Operation name which will send this request out,
28 // each operation should has unique request name, so that we can get operation's name from this request.
29 // Note: this is not true for response, multiple operations may have the same response name,
30 // so we can not get operation's name from response.
31 inline virtual const char* GetServiceRequestName() const override { return "AddPermission"; }
32
33 AWS_LAMBDA_API Aws::String SerializePayload() const override;
34
35 AWS_LAMBDA_API void AddQueryStringParameters(Aws::Http::URI& uri) const override;
36
38
50 inline const Aws::String& GetFunctionName() const { return m_functionName; }
51 inline bool FunctionNameHasBeenSet() const { return m_functionNameHasBeenSet; }
52 template <typename FunctionNameT = Aws::String>
53 void SetFunctionName(FunctionNameT&& value) {
54 m_functionNameHasBeenSet = true;
55 m_functionName = std::forward<FunctionNameT>(value);
56 }
57 template <typename FunctionNameT = Aws::String>
58 AddPermissionRequest& WithFunctionName(FunctionNameT&& value) {
59 SetFunctionName(std::forward<FunctionNameT>(value));
60 return *this;
61 }
63
65
69 inline const Aws::String& GetStatementId() const { return m_statementId; }
70 inline bool StatementIdHasBeenSet() const { return m_statementIdHasBeenSet; }
71 template <typename StatementIdT = Aws::String>
72 void SetStatementId(StatementIdT&& value) {
73 m_statementIdHasBeenSet = true;
74 m_statementId = std::forward<StatementIdT>(value);
75 }
76 template <typename StatementIdT = Aws::String>
77 AddPermissionRequest& WithStatementId(StatementIdT&& value) {
78 SetStatementId(std::forward<StatementIdT>(value));
79 return *this;
80 }
82
84
88 inline const Aws::String& GetAction() const { return m_action; }
89 inline bool ActionHasBeenSet() const { return m_actionHasBeenSet; }
90 template <typename ActionT = Aws::String>
91 void SetAction(ActionT&& value) {
92 m_actionHasBeenSet = true;
93 m_action = std::forward<ActionT>(value);
94 }
95 template <typename ActionT = Aws::String>
96 AddPermissionRequest& WithAction(ActionT&& value) {
97 SetAction(std::forward<ActionT>(value));
98 return *this;
99 }
101
103
109 inline const Aws::String& GetPrincipal() const { return m_principal; }
110 inline bool PrincipalHasBeenSet() const { return m_principalHasBeenSet; }
111 template <typename PrincipalT = Aws::String>
112 void SetPrincipal(PrincipalT&& value) {
113 m_principalHasBeenSet = true;
114 m_principal = std::forward<PrincipalT>(value);
115 }
116 template <typename PrincipalT = Aws::String>
117 AddPermissionRequest& WithPrincipal(PrincipalT&& value) {
118 SetPrincipal(std::forward<PrincipalT>(value));
119 return *this;
120 }
122
124
130 inline const Aws::String& GetSourceArn() const { return m_sourceArn; }
131 inline bool SourceArnHasBeenSet() const { return m_sourceArnHasBeenSet; }
132 template <typename SourceArnT = Aws::String>
133 void SetSourceArn(SourceArnT&& value) {
134 m_sourceArnHasBeenSet = true;
135 m_sourceArn = std::forward<SourceArnT>(value);
136 }
137 template <typename SourceArnT = Aws::String>
138 AddPermissionRequest& WithSourceArn(SourceArnT&& value) {
139 SetSourceArn(std::forward<SourceArnT>(value));
140 return *this;
141 }
143
145
151 inline const Aws::String& GetSourceAccount() const { return m_sourceAccount; }
152 inline bool SourceAccountHasBeenSet() const { return m_sourceAccountHasBeenSet; }
153 template <typename SourceAccountT = Aws::String>
154 void SetSourceAccount(SourceAccountT&& value) {
155 m_sourceAccountHasBeenSet = true;
156 m_sourceAccount = std::forward<SourceAccountT>(value);
157 }
158 template <typename SourceAccountT = Aws::String>
159 AddPermissionRequest& WithSourceAccount(SourceAccountT&& value) {
160 SetSourceAccount(std::forward<SourceAccountT>(value));
161 return *this;
162 }
164
166
169 inline const Aws::String& GetEventSourceToken() const { return m_eventSourceToken; }
170 inline bool EventSourceTokenHasBeenSet() const { return m_eventSourceTokenHasBeenSet; }
171 template <typename EventSourceTokenT = Aws::String>
172 void SetEventSourceToken(EventSourceTokenT&& value) {
173 m_eventSourceTokenHasBeenSet = true;
174 m_eventSourceToken = std::forward<EventSourceTokenT>(value);
175 }
176 template <typename EventSourceTokenT = Aws::String>
177 AddPermissionRequest& WithEventSourceToken(EventSourceTokenT&& value) {
178 SetEventSourceToken(std::forward<EventSourceTokenT>(value));
179 return *this;
180 }
182
184
188 inline const Aws::String& GetQualifier() const { return m_qualifier; }
189 inline bool QualifierHasBeenSet() const { return m_qualifierHasBeenSet; }
190 template <typename QualifierT = Aws::String>
191 void SetQualifier(QualifierT&& value) {
192 m_qualifierHasBeenSet = true;
193 m_qualifier = std::forward<QualifierT>(value);
194 }
195 template <typename QualifierT = Aws::String>
196 AddPermissionRequest& WithQualifier(QualifierT&& value) {
197 SetQualifier(std::forward<QualifierT>(value));
198 return *this;
199 }
201
203
208 inline const Aws::String& GetRevisionId() const { return m_revisionId; }
209 inline bool RevisionIdHasBeenSet() const { return m_revisionIdHasBeenSet; }
210 template <typename RevisionIdT = Aws::String>
211 void SetRevisionId(RevisionIdT&& value) {
212 m_revisionIdHasBeenSet = true;
213 m_revisionId = std::forward<RevisionIdT>(value);
214 }
215 template <typename RevisionIdT = Aws::String>
216 AddPermissionRequest& WithRevisionId(RevisionIdT&& value) {
217 SetRevisionId(std::forward<RevisionIdT>(value));
218 return *this;
219 }
221
223
227 inline const Aws::String& GetPrincipalOrgID() const { return m_principalOrgID; }
228 inline bool PrincipalOrgIDHasBeenSet() const { return m_principalOrgIDHasBeenSet; }
229 template <typename PrincipalOrgIDT = Aws::String>
230 void SetPrincipalOrgID(PrincipalOrgIDT&& value) {
231 m_principalOrgIDHasBeenSet = true;
232 m_principalOrgID = std::forward<PrincipalOrgIDT>(value);
233 }
234 template <typename PrincipalOrgIDT = Aws::String>
235 AddPermissionRequest& WithPrincipalOrgID(PrincipalOrgIDT&& value) {
236 SetPrincipalOrgID(std::forward<PrincipalOrgIDT>(value));
237 return *this;
238 }
240
242
250 inline FunctionUrlAuthType GetFunctionUrlAuthType() const { return m_functionUrlAuthType; }
251 inline bool FunctionUrlAuthTypeHasBeenSet() const { return m_functionUrlAuthTypeHasBeenSet; }
253 m_functionUrlAuthTypeHasBeenSet = true;
254 m_functionUrlAuthType = value;
255 }
258 return *this;
259 }
261
263
270 inline bool GetInvokedViaFunctionUrl() const { return m_invokedViaFunctionUrl; }
271 inline bool InvokedViaFunctionUrlHasBeenSet() const { return m_invokedViaFunctionUrlHasBeenSet; }
272 inline void SetInvokedViaFunctionUrl(bool value) {
273 m_invokedViaFunctionUrlHasBeenSet = true;
274 m_invokedViaFunctionUrl = value;
275 }
278 return *this;
279 }
281 private:
282 Aws::String m_functionName;
283 bool m_functionNameHasBeenSet = false;
284
285 Aws::String m_statementId;
286 bool m_statementIdHasBeenSet = false;
287
288 Aws::String m_action;
289 bool m_actionHasBeenSet = false;
290
291 Aws::String m_principal;
292 bool m_principalHasBeenSet = false;
293
294 Aws::String m_sourceArn;
295 bool m_sourceArnHasBeenSet = false;
296
297 Aws::String m_sourceAccount;
298 bool m_sourceAccountHasBeenSet = false;
299
300 Aws::String m_eventSourceToken;
301 bool m_eventSourceTokenHasBeenSet = false;
302
303 Aws::String m_qualifier;
304 bool m_qualifierHasBeenSet = false;
305
306 Aws::String m_revisionId;
307 bool m_revisionIdHasBeenSet = false;
308
309 Aws::String m_principalOrgID;
310 bool m_principalOrgIDHasBeenSet = false;
311
313 bool m_functionUrlAuthTypeHasBeenSet = false;
314
315 bool m_invokedViaFunctionUrl{false};
316 bool m_invokedViaFunctionUrlHasBeenSet = false;
317};
318
319} // namespace Model
320} // namespace Lambda
321} // namespace Aws
AddPermissionRequest & WithFunctionName(FunctionNameT &&value)
void SetSourceAccount(SourceAccountT &&value)
AWS_LAMBDA_API AddPermissionRequest()=default
const Aws::String & GetEventSourceToken() const
FunctionUrlAuthType GetFunctionUrlAuthType() const
AWS_LAMBDA_API Aws::String SerializePayload() const override
virtual const char * GetServiceRequestName() const override
void SetEventSourceToken(EventSourceTokenT &&value)
void SetFunctionUrlAuthType(FunctionUrlAuthType value)
AddPermissionRequest & WithStatementId(StatementIdT &&value)
AddPermissionRequest & WithInvokedViaFunctionUrl(bool value)
AddPermissionRequest & WithQualifier(QualifierT &&value)
AddPermissionRequest & WithEventSourceToken(EventSourceTokenT &&value)
AddPermissionRequest & WithAction(ActionT &&value)
AddPermissionRequest & WithSourceArn(SourceArnT &&value)
void SetPrincipalOrgID(PrincipalOrgIDT &&value)
AddPermissionRequest & WithPrincipal(PrincipalT &&value)
AWS_LAMBDA_API void AddQueryStringParameters(Aws::Http::URI &uri) const override
AddPermissionRequest & WithSourceAccount(SourceAccountT &&value)
AddPermissionRequest & WithRevisionId(RevisionIdT &&value)
AddPermissionRequest & WithFunctionUrlAuthType(FunctionUrlAuthType value)
AddPermissionRequest & WithPrincipalOrgID(PrincipalOrgIDT &&value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String