AWS SDK for C++

AWS SDK for C++ Version 1.11.743

Loading...
Searching...
No Matches
CreateRelayRequest.h
1
6#pragma once
7#include <aws/core/utils/UUID.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/mailmanager/MailManagerRequest.h>
11#include <aws/mailmanager/MailManager_EXPORTS.h>
12#include <aws/mailmanager/model/RelayAuthentication.h>
13#include <aws/mailmanager/model/Tag.h>
14
15#include <utility>
16
17namespace Aws {
18namespace MailManager {
19namespace Model {
20
24 public:
25 AWS_MAILMANAGER_API CreateRelayRequest() = 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 "CreateRelay"; }
32
33 AWS_MAILMANAGER_API Aws::String SerializePayload() const override;
34
35 AWS_MAILMANAGER_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override;
36
38
42 inline const Aws::String& GetClientToken() const { return m_clientToken; }
43 inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; }
44 template <typename ClientTokenT = Aws::String>
45 void SetClientToken(ClientTokenT&& value) {
46 m_clientTokenHasBeenSet = true;
47 m_clientToken = std::forward<ClientTokenT>(value);
48 }
49 template <typename ClientTokenT = Aws::String>
50 CreateRelayRequest& WithClientToken(ClientTokenT&& value) {
51 SetClientToken(std::forward<ClientTokenT>(value));
52 return *this;
53 }
55
57
60 inline const Aws::String& GetRelayName() const { return m_relayName; }
61 inline bool RelayNameHasBeenSet() const { return m_relayNameHasBeenSet; }
62 template <typename RelayNameT = Aws::String>
63 void SetRelayName(RelayNameT&& value) {
64 m_relayNameHasBeenSet = true;
65 m_relayName = std::forward<RelayNameT>(value);
66 }
67 template <typename RelayNameT = Aws::String>
68 CreateRelayRequest& WithRelayName(RelayNameT&& value) {
69 SetRelayName(std::forward<RelayNameT>(value));
70 return *this;
71 }
73
75
78 inline const Aws::String& GetServerName() const { return m_serverName; }
79 inline bool ServerNameHasBeenSet() const { return m_serverNameHasBeenSet; }
80 template <typename ServerNameT = Aws::String>
81 void SetServerName(ServerNameT&& value) {
82 m_serverNameHasBeenSet = true;
83 m_serverName = std::forward<ServerNameT>(value);
84 }
85 template <typename ServerNameT = Aws::String>
86 CreateRelayRequest& WithServerName(ServerNameT&& value) {
87 SetServerName(std::forward<ServerNameT>(value));
88 return *this;
89 }
91
93
96 inline int GetServerPort() const { return m_serverPort; }
97 inline bool ServerPortHasBeenSet() const { return m_serverPortHasBeenSet; }
98 inline void SetServerPort(int value) {
99 m_serverPortHasBeenSet = true;
100 m_serverPort = value;
101 }
103 SetServerPort(value);
104 return *this;
105 }
107
109
113 inline const RelayAuthentication& GetAuthentication() const { return m_authentication; }
114 inline bool AuthenticationHasBeenSet() const { return m_authenticationHasBeenSet; }
115 template <typename AuthenticationT = RelayAuthentication>
116 void SetAuthentication(AuthenticationT&& value) {
117 m_authenticationHasBeenSet = true;
118 m_authentication = std::forward<AuthenticationT>(value);
119 }
120 template <typename AuthenticationT = RelayAuthentication>
121 CreateRelayRequest& WithAuthentication(AuthenticationT&& value) {
122 SetAuthentication(std::forward<AuthenticationT>(value));
123 return *this;
124 }
126
128
132 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
133 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
134 template <typename TagsT = Aws::Vector<Tag>>
135 void SetTags(TagsT&& value) {
136 m_tagsHasBeenSet = true;
137 m_tags = std::forward<TagsT>(value);
138 }
139 template <typename TagsT = Aws::Vector<Tag>>
140 CreateRelayRequest& WithTags(TagsT&& value) {
141 SetTags(std::forward<TagsT>(value));
142 return *this;
143 }
144 template <typename TagsT = Tag>
145 CreateRelayRequest& AddTags(TagsT&& value) {
146 m_tagsHasBeenSet = true;
147 m_tags.emplace_back(std::forward<TagsT>(value));
148 return *this;
149 }
151 private:
153
154 Aws::String m_relayName;
155
156 Aws::String m_serverName;
157
158 int m_serverPort{0};
159
160 RelayAuthentication m_authentication;
161
162 Aws::Vector<Tag> m_tags;
163 bool m_clientTokenHasBeenSet = true;
164 bool m_relayNameHasBeenSet = false;
165 bool m_serverNameHasBeenSet = false;
166 bool m_serverPortHasBeenSet = false;
167 bool m_authenticationHasBeenSet = false;
168 bool m_tagsHasBeenSet = false;
169};
170
171} // namespace Model
172} // namespace MailManager
173} // namespace Aws
const Aws::Vector< Tag > & GetTags() const
const RelayAuthentication & GetAuthentication() const
virtual const char * GetServiceRequestName() const override
CreateRelayRequest & WithServerName(ServerNameT &&value)
CreateRelayRequest & WithAuthentication(AuthenticationT &&value)
AWS_MAILMANAGER_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override
CreateRelayRequest & AddTags(TagsT &&value)
void SetAuthentication(AuthenticationT &&value)
CreateRelayRequest & WithServerPort(int value)
CreateRelayRequest & WithClientToken(ClientTokenT &&value)
AWS_MAILMANAGER_API Aws::String SerializePayload() const override
AWS_MAILMANAGER_API CreateRelayRequest()=default
CreateRelayRequest & WithTags(TagsT &&value)
CreateRelayRequest & WithRelayName(RelayNameT &&value)
static Aws::Utils::UUID PseudoRandomUUID()
Aws::Map< Aws::String, Aws::String > HeaderValueCollection
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector