AWS SDK for C++

AWS SDK for C++ Version 1.11.744

Loading...
Searching...
No Matches
Session.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSMap.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <aws/glue/Glue_EXPORTS.h>
11#include <aws/glue/model/ConnectionsList.h>
12#include <aws/glue/model/SessionCommand.h>
13#include <aws/glue/model/SessionStatus.h>
14#include <aws/glue/model/WorkerType.h>
15
16#include <utility>
17
18namespace Aws {
19namespace Utils {
20namespace Json {
21class JsonValue;
22class JsonView;
23} // namespace Json
24} // namespace Utils
25namespace Glue {
26namespace Model {
27
34class Session {
35 public:
36 AWS_GLUE_API Session() = default;
37 AWS_GLUE_API Session(Aws::Utils::Json::JsonView jsonValue);
40
42
45 inline const Aws::String& GetId() const { return m_id; }
46 inline bool IdHasBeenSet() const { return m_idHasBeenSet; }
47 template <typename IdT = Aws::String>
48 void SetId(IdT&& value) {
49 m_idHasBeenSet = true;
50 m_id = std::forward<IdT>(value);
51 }
52 template <typename IdT = Aws::String>
53 Session& WithId(IdT&& value) {
54 SetId(std::forward<IdT>(value));
55 return *this;
56 }
58
60
63 inline const Aws::Utils::DateTime& GetCreatedOn() const { return m_createdOn; }
64 inline bool CreatedOnHasBeenSet() const { return m_createdOnHasBeenSet; }
65 template <typename CreatedOnT = Aws::Utils::DateTime>
66 void SetCreatedOn(CreatedOnT&& value) {
67 m_createdOnHasBeenSet = true;
68 m_createdOn = std::forward<CreatedOnT>(value);
69 }
70 template <typename CreatedOnT = Aws::Utils::DateTime>
71 Session& WithCreatedOn(CreatedOnT&& value) {
72 SetCreatedOn(std::forward<CreatedOnT>(value));
73 return *this;
74 }
76
78
81 inline SessionStatus GetStatus() const { return m_status; }
82 inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; }
83 inline void SetStatus(SessionStatus value) {
84 m_statusHasBeenSet = true;
85 m_status = value;
86 }
88 SetStatus(value);
89 return *this;
90 }
92
94
97 inline const Aws::String& GetErrorMessage() const { return m_errorMessage; }
98 inline bool ErrorMessageHasBeenSet() const { return m_errorMessageHasBeenSet; }
99 template <typename ErrorMessageT = Aws::String>
100 void SetErrorMessage(ErrorMessageT&& value) {
101 m_errorMessageHasBeenSet = true;
102 m_errorMessage = std::forward<ErrorMessageT>(value);
103 }
104 template <typename ErrorMessageT = Aws::String>
105 Session& WithErrorMessage(ErrorMessageT&& value) {
106 SetErrorMessage(std::forward<ErrorMessageT>(value));
107 return *this;
108 }
110
112
115 inline const Aws::String& GetDescription() const { return m_description; }
116 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
117 template <typename DescriptionT = Aws::String>
118 void SetDescription(DescriptionT&& value) {
119 m_descriptionHasBeenSet = true;
120 m_description = std::forward<DescriptionT>(value);
121 }
122 template <typename DescriptionT = Aws::String>
123 Session& WithDescription(DescriptionT&& value) {
124 SetDescription(std::forward<DescriptionT>(value));
125 return *this;
126 }
128
130
134 inline const Aws::String& GetRole() const { return m_role; }
135 inline bool RoleHasBeenSet() const { return m_roleHasBeenSet; }
136 template <typename RoleT = Aws::String>
137 void SetRole(RoleT&& value) {
138 m_roleHasBeenSet = true;
139 m_role = std::forward<RoleT>(value);
140 }
141 template <typename RoleT = Aws::String>
142 Session& WithRole(RoleT&& value) {
143 SetRole(std::forward<RoleT>(value));
144 return *this;
145 }
147
149
152 inline const SessionCommand& GetCommand() const { return m_command; }
153 inline bool CommandHasBeenSet() const { return m_commandHasBeenSet; }
154 template <typename CommandT = SessionCommand>
155 void SetCommand(CommandT&& value) {
156 m_commandHasBeenSet = true;
157 m_command = std::forward<CommandT>(value);
158 }
159 template <typename CommandT = SessionCommand>
160 Session& WithCommand(CommandT&& value) {
161 SetCommand(std::forward<CommandT>(value));
162 return *this;
163 }
165
167
170 inline const Aws::Map<Aws::String, Aws::String>& GetDefaultArguments() const { return m_defaultArguments; }
171 inline bool DefaultArgumentsHasBeenSet() const { return m_defaultArgumentsHasBeenSet; }
172 template <typename DefaultArgumentsT = Aws::Map<Aws::String, Aws::String>>
173 void SetDefaultArguments(DefaultArgumentsT&& value) {
174 m_defaultArgumentsHasBeenSet = true;
175 m_defaultArguments = std::forward<DefaultArgumentsT>(value);
176 }
177 template <typename DefaultArgumentsT = Aws::Map<Aws::String, Aws::String>>
178 Session& WithDefaultArguments(DefaultArgumentsT&& value) {
179 SetDefaultArguments(std::forward<DefaultArgumentsT>(value));
180 return *this;
181 }
182 template <typename DefaultArgumentsKeyT = Aws::String, typename DefaultArgumentsValueT = Aws::String>
183 Session& AddDefaultArguments(DefaultArgumentsKeyT&& key, DefaultArgumentsValueT&& value) {
184 m_defaultArgumentsHasBeenSet = true;
185 m_defaultArguments.emplace(std::forward<DefaultArgumentsKeyT>(key), std::forward<DefaultArgumentsValueT>(value));
186 return *this;
187 }
189
191
194 inline const ConnectionsList& GetConnections() const { return m_connections; }
195 inline bool ConnectionsHasBeenSet() const { return m_connectionsHasBeenSet; }
196 template <typename ConnectionsT = ConnectionsList>
197 void SetConnections(ConnectionsT&& value) {
198 m_connectionsHasBeenSet = true;
199 m_connections = std::forward<ConnectionsT>(value);
200 }
201 template <typename ConnectionsT = ConnectionsList>
202 Session& WithConnections(ConnectionsT&& value) {
203 SetConnections(std::forward<ConnectionsT>(value));
204 return *this;
205 }
207
209
212 inline double GetProgress() const { return m_progress; }
213 inline bool ProgressHasBeenSet() const { return m_progressHasBeenSet; }
214 inline void SetProgress(double value) {
215 m_progressHasBeenSet = true;
216 m_progress = value;
217 }
218 inline Session& WithProgress(double value) {
219 SetProgress(value);
220 return *this;
221 }
223
225
230 inline double GetMaxCapacity() const { return m_maxCapacity; }
231 inline bool MaxCapacityHasBeenSet() const { return m_maxCapacityHasBeenSet; }
232 inline void SetMaxCapacity(double value) {
233 m_maxCapacityHasBeenSet = true;
234 m_maxCapacity = value;
235 }
236 inline Session& WithMaxCapacity(double value) {
237 SetMaxCapacity(value);
238 return *this;
239 }
241
243
247 inline const Aws::String& GetSecurityConfiguration() const { return m_securityConfiguration; }
248 inline bool SecurityConfigurationHasBeenSet() const { return m_securityConfigurationHasBeenSet; }
249 template <typename SecurityConfigurationT = Aws::String>
250 void SetSecurityConfiguration(SecurityConfigurationT&& value) {
251 m_securityConfigurationHasBeenSet = true;
252 m_securityConfiguration = std::forward<SecurityConfigurationT>(value);
253 }
254 template <typename SecurityConfigurationT = Aws::String>
255 Session& WithSecurityConfiguration(SecurityConfigurationT&& value) {
256 SetSecurityConfiguration(std::forward<SecurityConfigurationT>(value));
257 return *this;
258 }
260
262
266 inline const Aws::String& GetGlueVersion() const { return m_glueVersion; }
267 inline bool GlueVersionHasBeenSet() const { return m_glueVersionHasBeenSet; }
268 template <typename GlueVersionT = Aws::String>
269 void SetGlueVersion(GlueVersionT&& value) {
270 m_glueVersionHasBeenSet = true;
271 m_glueVersion = std::forward<GlueVersionT>(value);
272 }
273 template <typename GlueVersionT = Aws::String>
274 Session& WithGlueVersion(GlueVersionT&& value) {
275 SetGlueVersion(std::forward<GlueVersionT>(value));
276 return *this;
277 }
279
281
285 inline int GetNumberOfWorkers() const { return m_numberOfWorkers; }
286 inline bool NumberOfWorkersHasBeenSet() const { return m_numberOfWorkersHasBeenSet; }
287 inline void SetNumberOfWorkers(int value) {
288 m_numberOfWorkersHasBeenSet = true;
289 m_numberOfWorkers = value;
290 }
291 inline Session& WithNumberOfWorkers(int value) {
292 SetNumberOfWorkers(value);
293 return *this;
294 }
296
298
304 inline WorkerType GetWorkerType() const { return m_workerType; }
305 inline bool WorkerTypeHasBeenSet() const { return m_workerTypeHasBeenSet; }
306 inline void SetWorkerType(WorkerType value) {
307 m_workerTypeHasBeenSet = true;
308 m_workerType = value;
309 }
311 SetWorkerType(value);
312 return *this;
313 }
315
317
320 inline const Aws::Utils::DateTime& GetCompletedOn() const { return m_completedOn; }
321 inline bool CompletedOnHasBeenSet() const { return m_completedOnHasBeenSet; }
322 template <typename CompletedOnT = Aws::Utils::DateTime>
323 void SetCompletedOn(CompletedOnT&& value) {
324 m_completedOnHasBeenSet = true;
325 m_completedOn = std::forward<CompletedOnT>(value);
326 }
327 template <typename CompletedOnT = Aws::Utils::DateTime>
328 Session& WithCompletedOn(CompletedOnT&& value) {
329 SetCompletedOn(std::forward<CompletedOnT>(value));
330 return *this;
331 }
333
335
338 inline double GetExecutionTime() const { return m_executionTime; }
339 inline bool ExecutionTimeHasBeenSet() const { return m_executionTimeHasBeenSet; }
340 inline void SetExecutionTime(double value) {
341 m_executionTimeHasBeenSet = true;
342 m_executionTime = value;
343 }
344 inline Session& WithExecutionTime(double value) {
345 SetExecutionTime(value);
346 return *this;
347 }
349
351
354 inline double GetDPUSeconds() const { return m_dPUSeconds; }
355 inline bool DPUSecondsHasBeenSet() const { return m_dPUSecondsHasBeenSet; }
356 inline void SetDPUSeconds(double value) {
357 m_dPUSecondsHasBeenSet = true;
358 m_dPUSeconds = value;
359 }
360 inline Session& WithDPUSeconds(double value) {
361 SetDPUSeconds(value);
362 return *this;
363 }
365
367
370 inline int GetIdleTimeout() const { return m_idleTimeout; }
371 inline bool IdleTimeoutHasBeenSet() const { return m_idleTimeoutHasBeenSet; }
372 inline void SetIdleTimeout(int value) {
373 m_idleTimeoutHasBeenSet = true;
374 m_idleTimeout = value;
375 }
376 inline Session& WithIdleTimeout(int value) {
377 SetIdleTimeout(value);
378 return *this;
379 }
381
383
386 inline const Aws::String& GetProfileName() const { return m_profileName; }
387 inline bool ProfileNameHasBeenSet() const { return m_profileNameHasBeenSet; }
388 template <typename ProfileNameT = Aws::String>
389 void SetProfileName(ProfileNameT&& value) {
390 m_profileNameHasBeenSet = true;
391 m_profileName = std::forward<ProfileNameT>(value);
392 }
393 template <typename ProfileNameT = Aws::String>
394 Session& WithProfileName(ProfileNameT&& value) {
395 SetProfileName(std::forward<ProfileNameT>(value));
396 return *this;
397 }
399 private:
400 Aws::String m_id;
401
402 Aws::Utils::DateTime m_createdOn{};
403
405
406 Aws::String m_errorMessage;
407
408 Aws::String m_description;
409
410 Aws::String m_role;
411
412 SessionCommand m_command;
413
414 Aws::Map<Aws::String, Aws::String> m_defaultArguments;
415
416 ConnectionsList m_connections;
417
418 double m_progress{0.0};
419
420 double m_maxCapacity{0.0};
421
422 Aws::String m_securityConfiguration;
423
424 Aws::String m_glueVersion;
425
426 int m_numberOfWorkers{0};
427
428 WorkerType m_workerType{WorkerType::NOT_SET};
429
430 Aws::Utils::DateTime m_completedOn{};
431
432 double m_executionTime{0.0};
433
434 double m_dPUSeconds{0.0};
435
436 int m_idleTimeout{0};
437
438 Aws::String m_profileName;
439 bool m_idHasBeenSet = false;
440 bool m_createdOnHasBeenSet = false;
441 bool m_statusHasBeenSet = false;
442 bool m_errorMessageHasBeenSet = false;
443 bool m_descriptionHasBeenSet = false;
444 bool m_roleHasBeenSet = false;
445 bool m_commandHasBeenSet = false;
446 bool m_defaultArgumentsHasBeenSet = false;
447 bool m_connectionsHasBeenSet = false;
448 bool m_progressHasBeenSet = false;
449 bool m_maxCapacityHasBeenSet = false;
450 bool m_securityConfigurationHasBeenSet = false;
451 bool m_glueVersionHasBeenSet = false;
452 bool m_numberOfWorkersHasBeenSet = false;
453 bool m_workerTypeHasBeenSet = false;
454 bool m_completedOnHasBeenSet = false;
455 bool m_executionTimeHasBeenSet = false;
456 bool m_dPUSecondsHasBeenSet = false;
457 bool m_idleTimeoutHasBeenSet = false;
458 bool m_profileNameHasBeenSet = false;
459};
460
461} // namespace Model
462} // namespace Glue
463} // namespace Aws
bool ProfileNameHasBeenSet() const
Definition Session.h:387
AWS_GLUE_API Session()=default
bool DefaultArgumentsHasBeenSet() const
Definition Session.h:171
void SetIdleTimeout(int value)
Definition Session.h:372
AWS_GLUE_API Aws::Utils::Json::JsonValue Jsonize() const
WorkerType GetWorkerType() const
Definition Session.h:304
const Aws::String & GetSecurityConfiguration() const
Definition Session.h:247
bool ConnectionsHasBeenSet() const
Definition Session.h:195
bool NumberOfWorkersHasBeenSet() const
Definition Session.h:286
void SetDefaultArguments(DefaultArgumentsT &&value)
Definition Session.h:173
bool ErrorMessageHasBeenSet() const
Definition Session.h:98
bool CommandHasBeenSet() const
Definition Session.h:153
void SetStatus(SessionStatus value)
Definition Session.h:83
bool CompletedOnHasBeenSet() const
Definition Session.h:321
int GetIdleTimeout() const
Definition Session.h:370
Session & WithWorkerType(WorkerType value)
Definition Session.h:310
double GetExecutionTime() const
Definition Session.h:338
void SetCommand(CommandT &&value)
Definition Session.h:155
Session & AddDefaultArguments(DefaultArgumentsKeyT &&key, DefaultArgumentsValueT &&value)
Definition Session.h:183
void SetConnections(ConnectionsT &&value)
Definition Session.h:197
Session & WithIdleTimeout(int value)
Definition Session.h:376
const Aws::String & GetId() const
Definition Session.h:45
Session & WithCreatedOn(CreatedOnT &&value)
Definition Session.h:71
void SetCreatedOn(CreatedOnT &&value)
Definition Session.h:66
void SetExecutionTime(double value)
Definition Session.h:340
const Aws::String & GetProfileName() const
Definition Session.h:386
void SetMaxCapacity(double value)
Definition Session.h:232
double GetMaxCapacity() const
Definition Session.h:230
Session & WithDefaultArguments(DefaultArgumentsT &&value)
Definition Session.h:178
bool RoleHasBeenSet() const
Definition Session.h:135
const ConnectionsList & GetConnections() const
Definition Session.h:194
void SetSecurityConfiguration(SecurityConfigurationT &&value)
Definition Session.h:250
const Aws::String & GetDescription() const
Definition Session.h:115
bool StatusHasBeenSet() const
Definition Session.h:82
Session & WithGlueVersion(GlueVersionT &&value)
Definition Session.h:274
void SetDPUSeconds(double value)
Definition Session.h:356
void SetErrorMessage(ErrorMessageT &&value)
Definition Session.h:100
const Aws::String & GetRole() const
Definition Session.h:134
const Aws::Utils::DateTime & GetCompletedOn() const
Definition Session.h:320
bool DPUSecondsHasBeenSet() const
Definition Session.h:355
void SetProgress(double value)
Definition Session.h:214
Session & WithConnections(ConnectionsT &&value)
Definition Session.h:202
void SetRole(RoleT &&value)
Definition Session.h:137
double GetProgress() const
Definition Session.h:212
Session & WithNumberOfWorkers(int value)
Definition Session.h:291
Session & WithDPUSeconds(double value)
Definition Session.h:360
Session & WithStatus(SessionStatus value)
Definition Session.h:87
const SessionCommand & GetCommand() const
Definition Session.h:152
Session & WithProfileName(ProfileNameT &&value)
Definition Session.h:394
double GetDPUSeconds() const
Definition Session.h:354
void SetGlueVersion(GlueVersionT &&value)
Definition Session.h:269
bool DescriptionHasBeenSet() const
Definition Session.h:116
int GetNumberOfWorkers() const
Definition Session.h:285
void SetWorkerType(WorkerType value)
Definition Session.h:306
const Aws::String & GetErrorMessage() const
Definition Session.h:97
bool ExecutionTimeHasBeenSet() const
Definition Session.h:339
bool MaxCapacityHasBeenSet() const
Definition Session.h:231
bool CreatedOnHasBeenSet() const
Definition Session.h:64
Session & WithExecutionTime(double value)
Definition Session.h:344
void SetProfileName(ProfileNameT &&value)
Definition Session.h:389
Session & WithMaxCapacity(double value)
Definition Session.h:236
bool ProgressHasBeenSet() const
Definition Session.h:213
bool SecurityConfigurationHasBeenSet() const
Definition Session.h:248
SessionStatus GetStatus() const
Definition Session.h:81
void SetNumberOfWorkers(int value)
Definition Session.h:287
Session & WithDescription(DescriptionT &&value)
Definition Session.h:123
Session & WithCommand(CommandT &&value)
Definition Session.h:160
Session & WithProgress(double value)
Definition Session.h:218
const Aws::Utils::DateTime & GetCreatedOn() const
Definition Session.h:63
const Aws::Map< Aws::String, Aws::String > & GetDefaultArguments() const
Definition Session.h:170
bool WorkerTypeHasBeenSet() const
Definition Session.h:305
void SetId(IdT &&value)
Definition Session.h:48
Session & WithId(IdT &&value)
Definition Session.h:53
void SetCompletedOn(CompletedOnT &&value)
Definition Session.h:323
Session & WithSecurityConfiguration(SecurityConfigurationT &&value)
Definition Session.h:255
Session & WithCompletedOn(CompletedOnT &&value)
Definition Session.h:328
bool IdleTimeoutHasBeenSet() const
Definition Session.h:371
const Aws::String & GetGlueVersion() const
Definition Session.h:266
void SetDescription(DescriptionT &&value)
Definition Session.h:118
bool IdHasBeenSet() const
Definition Session.h:46
AWS_GLUE_API Session(Aws::Utils::Json::JsonView jsonValue)
Session & WithErrorMessage(ErrorMessageT &&value)
Definition Session.h:105
AWS_GLUE_API Session & operator=(Aws::Utils::Json::JsonView jsonValue)
bool GlueVersionHasBeenSet() const
Definition Session.h:267
Session & WithRole(RoleT &&value)
Definition Session.h:142
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue