AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
Session.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/ssm/SSM_EXPORTS.h>
10#include <aws/ssm/model/AccessType.h>
11#include <aws/ssm/model/SessionManagerOutputUrl.h>
12#include <aws/ssm/model/SessionStatus.h>
13
14#include <utility>
15
16namespace Aws {
17namespace Utils {
18namespace Json {
19class JsonValue;
20class JsonView;
21} // namespace Json
22} // namespace Utils
23namespace SSM {
24namespace Model {
25
32class Session {
33 public:
34 AWS_SSM_API Session() = default;
35 AWS_SSM_API Session(Aws::Utils::Json::JsonView jsonValue);
38
40
43 inline const Aws::String& GetSessionId() const { return m_sessionId; }
44 inline bool SessionIdHasBeenSet() const { return m_sessionIdHasBeenSet; }
45 template <typename SessionIdT = Aws::String>
46 void SetSessionId(SessionIdT&& value) {
47 m_sessionIdHasBeenSet = true;
48 m_sessionId = std::forward<SessionIdT>(value);
49 }
50 template <typename SessionIdT = Aws::String>
51 Session& WithSessionId(SessionIdT&& value) {
52 SetSessionId(std::forward<SessionIdT>(value));
53 return *this;
54 }
56
58
61 inline const Aws::String& GetTarget() const { return m_target; }
62 inline bool TargetHasBeenSet() const { return m_targetHasBeenSet; }
63 template <typename TargetT = Aws::String>
64 void SetTarget(TargetT&& value) {
65 m_targetHasBeenSet = true;
66 m_target = std::forward<TargetT>(value);
67 }
68 template <typename TargetT = Aws::String>
69 Session& WithTarget(TargetT&& value) {
70 SetTarget(std::forward<TargetT>(value));
71 return *this;
72 }
74
76
79 inline SessionStatus GetStatus() const { return m_status; }
80 inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; }
81 inline void SetStatus(SessionStatus value) {
82 m_statusHasBeenSet = true;
83 m_status = value;
84 }
86 SetStatus(value);
87 return *this;
88 }
90
92
95 inline const Aws::Utils::DateTime& GetStartDate() const { return m_startDate; }
96 inline bool StartDateHasBeenSet() const { return m_startDateHasBeenSet; }
97 template <typename StartDateT = Aws::Utils::DateTime>
98 void SetStartDate(StartDateT&& value) {
99 m_startDateHasBeenSet = true;
100 m_startDate = std::forward<StartDateT>(value);
101 }
102 template <typename StartDateT = Aws::Utils::DateTime>
103 Session& WithStartDate(StartDateT&& value) {
104 SetStartDate(std::forward<StartDateT>(value));
105 return *this;
106 }
108
110
114 inline const Aws::Utils::DateTime& GetEndDate() const { return m_endDate; }
115 inline bool EndDateHasBeenSet() const { return m_endDateHasBeenSet; }
116 template <typename EndDateT = Aws::Utils::DateTime>
117 void SetEndDate(EndDateT&& value) {
118 m_endDateHasBeenSet = true;
119 m_endDate = std::forward<EndDateT>(value);
120 }
121 template <typename EndDateT = Aws::Utils::DateTime>
122 Session& WithEndDate(EndDateT&& value) {
123 SetEndDate(std::forward<EndDateT>(value));
124 return *this;
125 }
127
129
134 inline const Aws::String& GetDocumentName() const { return m_documentName; }
135 inline bool DocumentNameHasBeenSet() const { return m_documentNameHasBeenSet; }
136 template <typename DocumentNameT = Aws::String>
137 void SetDocumentName(DocumentNameT&& value) {
138 m_documentNameHasBeenSet = true;
139 m_documentName = std::forward<DocumentNameT>(value);
140 }
141 template <typename DocumentNameT = Aws::String>
142 Session& WithDocumentName(DocumentNameT&& value) {
143 SetDocumentName(std::forward<DocumentNameT>(value));
144 return *this;
145 }
147
149
152 inline const Aws::String& GetOwner() const { return m_owner; }
153 inline bool OwnerHasBeenSet() const { return m_ownerHasBeenSet; }
154 template <typename OwnerT = Aws::String>
155 void SetOwner(OwnerT&& value) {
156 m_ownerHasBeenSet = true;
157 m_owner = std::forward<OwnerT>(value);
158 }
159 template <typename OwnerT = Aws::String>
160 Session& WithOwner(OwnerT&& value) {
161 SetOwner(std::forward<OwnerT>(value));
162 return *this;
163 }
165
167
170 inline const Aws::String& GetReason() const { return m_reason; }
171 inline bool ReasonHasBeenSet() const { return m_reasonHasBeenSet; }
172 template <typename ReasonT = Aws::String>
173 void SetReason(ReasonT&& value) {
174 m_reasonHasBeenSet = true;
175 m_reason = std::forward<ReasonT>(value);
176 }
177 template <typename ReasonT = Aws::String>
178 Session& WithReason(ReasonT&& value) {
179 SetReason(std::forward<ReasonT>(value));
180 return *this;
181 }
183
185
188 inline const Aws::String& GetDetails() const { return m_details; }
189 inline bool DetailsHasBeenSet() const { return m_detailsHasBeenSet; }
190 template <typename DetailsT = Aws::String>
191 void SetDetails(DetailsT&& value) {
192 m_detailsHasBeenSet = true;
193 m_details = std::forward<DetailsT>(value);
194 }
195 template <typename DetailsT = Aws::String>
196 Session& WithDetails(DetailsT&& value) {
197 SetDetails(std::forward<DetailsT>(value));
198 return *this;
199 }
201
203
206 inline const SessionManagerOutputUrl& GetOutputUrl() const { return m_outputUrl; }
207 inline bool OutputUrlHasBeenSet() const { return m_outputUrlHasBeenSet; }
208 template <typename OutputUrlT = SessionManagerOutputUrl>
209 void SetOutputUrl(OutputUrlT&& value) {
210 m_outputUrlHasBeenSet = true;
211 m_outputUrl = std::forward<OutputUrlT>(value);
212 }
213 template <typename OutputUrlT = SessionManagerOutputUrl>
214 Session& WithOutputUrl(OutputUrlT&& value) {
215 SetOutputUrl(std::forward<OutputUrlT>(value));
216 return *this;
217 }
219
221
224 inline const Aws::String& GetMaxSessionDuration() const { return m_maxSessionDuration; }
225 inline bool MaxSessionDurationHasBeenSet() const { return m_maxSessionDurationHasBeenSet; }
226 template <typename MaxSessionDurationT = Aws::String>
227 void SetMaxSessionDuration(MaxSessionDurationT&& value) {
228 m_maxSessionDurationHasBeenSet = true;
229 m_maxSessionDuration = std::forward<MaxSessionDurationT>(value);
230 }
231 template <typename MaxSessionDurationT = Aws::String>
232 Session& WithMaxSessionDuration(MaxSessionDurationT&& value) {
233 SetMaxSessionDuration(std::forward<MaxSessionDurationT>(value));
234 return *this;
235 }
237
239
245 inline AccessType GetAccessType() const { return m_accessType; }
246 inline bool AccessTypeHasBeenSet() const { return m_accessTypeHasBeenSet; }
247 inline void SetAccessType(AccessType value) {
248 m_accessTypeHasBeenSet = true;
249 m_accessType = value;
250 }
252 SetAccessType(value);
253 return *this;
254 }
256 private:
257 Aws::String m_sessionId;
258
259 Aws::String m_target;
260
262
263 Aws::Utils::DateTime m_startDate{};
264
265 Aws::Utils::DateTime m_endDate{};
266
267 Aws::String m_documentName;
268
269 Aws::String m_owner;
270
271 Aws::String m_reason;
272
273 Aws::String m_details;
274
275 SessionManagerOutputUrl m_outputUrl;
276
277 Aws::String m_maxSessionDuration;
278
279 AccessType m_accessType{AccessType::NOT_SET};
280 bool m_sessionIdHasBeenSet = false;
281 bool m_targetHasBeenSet = false;
282 bool m_statusHasBeenSet = false;
283 bool m_startDateHasBeenSet = false;
284 bool m_endDateHasBeenSet = false;
285 bool m_documentNameHasBeenSet = false;
286 bool m_ownerHasBeenSet = false;
287 bool m_reasonHasBeenSet = false;
288 bool m_detailsHasBeenSet = false;
289 bool m_outputUrlHasBeenSet = false;
290 bool m_maxSessionDurationHasBeenSet = false;
291 bool m_accessTypeHasBeenSet = false;
292};
293
294} // namespace Model
295} // namespace SSM
296} // namespace Aws
AWS_SSM_API Session & operator=(Aws::Utils::Json::JsonView jsonValue)
void SetDocumentName(DocumentNameT &&value)
Definition Session.h:137
const Aws::String & GetDetails() const
Definition Session.h:188
Session & WithAccessType(AccessType value)
Definition Session.h:251
bool StartDateHasBeenSet() const
Definition Session.h:96
void SetSessionId(SessionIdT &&value)
Definition Session.h:46
const SessionManagerOutputUrl & GetOutputUrl() const
Definition Session.h:206
const Aws::String & GetMaxSessionDuration() const
Definition Session.h:224
bool TargetHasBeenSet() const
Definition Session.h:62
Session & WithEndDate(EndDateT &&value)
Definition Session.h:122
void SetOwner(OwnerT &&value)
Definition Session.h:155
bool OwnerHasBeenSet() const
Definition Session.h:153
const Aws::Utils::DateTime & GetStartDate() const
Definition Session.h:95
void SetAccessType(AccessType value)
Definition Session.h:247
SessionStatus GetStatus() const
Definition Session.h:79
void SetDetails(DetailsT &&value)
Definition Session.h:191
bool ReasonHasBeenSet() const
Definition Session.h:171
Session & WithOutputUrl(OutputUrlT &&value)
Definition Session.h:214
void SetStatus(SessionStatus value)
Definition Session.h:81
Session & WithDocumentName(DocumentNameT &&value)
Definition Session.h:142
void SetTarget(TargetT &&value)
Definition Session.h:64
AccessType GetAccessType() const
Definition Session.h:245
const Aws::String & GetSessionId() const
Definition Session.h:43
void SetOutputUrl(OutputUrlT &&value)
Definition Session.h:209
void SetReason(ReasonT &&value)
Definition Session.h:173
void SetEndDate(EndDateT &&value)
Definition Session.h:117
AWS_SSM_API Session()=default
AWS_SSM_API Aws::Utils::Json::JsonValue Jsonize() const
bool SessionIdHasBeenSet() const
Definition Session.h:44
bool StatusHasBeenSet() const
Definition Session.h:80
Session & WithReason(ReasonT &&value)
Definition Session.h:178
void SetMaxSessionDuration(MaxSessionDurationT &&value)
Definition Session.h:227
Session & WithStatus(SessionStatus value)
Definition Session.h:85
const Aws::String & GetDocumentName() const
Definition Session.h:134
Session & WithDetails(DetailsT &&value)
Definition Session.h:196
const Aws::String & GetOwner() const
Definition Session.h:152
bool AccessTypeHasBeenSet() const
Definition Session.h:246
bool OutputUrlHasBeenSet() const
Definition Session.h:207
Session & WithTarget(TargetT &&value)
Definition Session.h:69
bool MaxSessionDurationHasBeenSet() const
Definition Session.h:225
bool EndDateHasBeenSet() const
Definition Session.h:115
void SetStartDate(StartDateT &&value)
Definition Session.h:98
Session & WithStartDate(StartDateT &&value)
Definition Session.h:103
const Aws::Utils::DateTime & GetEndDate() const
Definition Session.h:114
const Aws::String & GetTarget() const
Definition Session.h:61
Session & WithOwner(OwnerT &&value)
Definition Session.h:160
const Aws::String & GetReason() const
Definition Session.h:170
Session & WithSessionId(SessionIdT &&value)
Definition Session.h:51
bool DetailsHasBeenSet() const
Definition Session.h:189
bool DocumentNameHasBeenSet() const
Definition Session.h:135
AWS_SSM_API Session(Aws::Utils::Json::JsonView jsonValue)
Session & WithMaxSessionDuration(MaxSessionDurationT &&value)
Definition Session.h:232
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue