AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
GetSessionTokenRequest.h
1
6#pragma once
7#include <aws/sts/STS_EXPORTS.h>
8#include <aws/sts/STSRequest.h>
9#include <aws/core/utils/memory/stl/AWSString.h>
10#include <utility>
11
12namespace Aws
13{
14namespace STS
15{
16namespace Model
17{
18
22 {
23 public:
24 AWS_STS_API GetSessionTokenRequest() = default;
25
26 // Service request name is the Operation name which will send this request out,
27 // each operation should has unique request name, so that we can get operation's name from this request.
28 // Note: this is not true for response, multiple operations may have the same response name,
29 // so we can not get operation's name from response.
30 inline virtual const char* GetServiceRequestName() const override { return "GetSessionToken"; }
31
32 AWS_STS_API Aws::String SerializePayload() const override;
33
34 protected:
35 AWS_STS_API void DumpBodyToUrl(Aws::Http::URI& uri ) const override;
36
37 public:
38
40
48 inline int GetDurationSeconds() const { return m_durationSeconds; }
49 inline bool DurationSecondsHasBeenSet() const { return m_durationSecondsHasBeenSet; }
50 inline void SetDurationSeconds(int value) { m_durationSecondsHasBeenSet = true; m_durationSeconds = value; }
51 inline GetSessionTokenRequest& WithDurationSeconds(int value) { SetDurationSeconds(value); return *this;}
53
55
68 inline const Aws::String& GetSerialNumber() const { return m_serialNumber; }
69 inline bool SerialNumberHasBeenSet() const { return m_serialNumberHasBeenSet; }
70 template<typename SerialNumberT = Aws::String>
71 void SetSerialNumber(SerialNumberT&& value) { m_serialNumberHasBeenSet = true; m_serialNumber = std::forward<SerialNumberT>(value); }
72 template<typename SerialNumberT = Aws::String>
73 GetSessionTokenRequest& WithSerialNumber(SerialNumberT&& value) { SetSerialNumber(std::forward<SerialNumberT>(value)); return *this;}
75
77
86 inline const Aws::String& GetTokenCode() const { return m_tokenCode; }
87 inline bool TokenCodeHasBeenSet() const { return m_tokenCodeHasBeenSet; }
88 template<typename TokenCodeT = Aws::String>
89 void SetTokenCode(TokenCodeT&& value) { m_tokenCodeHasBeenSet = true; m_tokenCode = std::forward<TokenCodeT>(value); }
90 template<typename TokenCodeT = Aws::String>
91 GetSessionTokenRequest& WithTokenCode(TokenCodeT&& value) { SetTokenCode(std::forward<TokenCodeT>(value)); return *this;}
93 private:
94
95 int m_durationSeconds{0};
96 bool m_durationSecondsHasBeenSet = false;
97
98 Aws::String m_serialNumber;
99 bool m_serialNumberHasBeenSet = false;
100
101 Aws::String m_tokenCode;
102 bool m_tokenCodeHasBeenSet = false;
103 };
104
105} // namespace Model
106} // namespace STS
107} // namespace Aws
GetSessionTokenRequest & WithTokenCode(TokenCodeT &&value)
virtual const char * GetServiceRequestName() const override
GetSessionTokenRequest & WithSerialNumber(SerialNumberT &&value)
AWS_STS_API void DumpBodyToUrl(Aws::Http::URI &uri) const override
GetSessionTokenRequest & WithDurationSeconds(int value)
AWS_STS_API Aws::String SerializePayload() const override
AWS_STS_API GetSessionTokenRequest()=default
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String