AWS SDK for C++

AWS SDK for C++ Version 1.11.747

Loading...
Searching...
No Matches
HttpGatewayRouteMatch.h
1
6#pragma once
7#include <aws/appmesh/AppMesh_EXPORTS.h>
8#include <aws/appmesh/model/GatewayRouteHostnameMatch.h>
9#include <aws/appmesh/model/HttpGatewayRouteHeader.h>
10#include <aws/appmesh/model/HttpMethod.h>
11#include <aws/appmesh/model/HttpPathMatch.h>
12#include <aws/appmesh/model/HttpQueryParameter.h>
13#include <aws/core/utils/memory/stl/AWSString.h>
14#include <aws/core/utils/memory/stl/AWSVector.h>
15
16#include <utility>
17
18namespace Aws {
19namespace Utils {
20namespace Json {
21class JsonValue;
22class JsonView;
23} // namespace Json
24} // namespace Utils
25namespace AppMesh {
26namespace Model {
27
35 public:
36 AWS_APPMESH_API HttpGatewayRouteMatch() = default;
39 AWS_APPMESH_API Aws::Utils::Json::JsonValue Jsonize() const;
40
42
45 inline const Aws::Vector<HttpGatewayRouteHeader>& GetHeaders() const { return m_headers; }
46 inline bool HeadersHasBeenSet() const { return m_headersHasBeenSet; }
47 template <typename HeadersT = Aws::Vector<HttpGatewayRouteHeader>>
48 void SetHeaders(HeadersT&& value) {
49 m_headersHasBeenSet = true;
50 m_headers = std::forward<HeadersT>(value);
51 }
52 template <typename HeadersT = Aws::Vector<HttpGatewayRouteHeader>>
54 SetHeaders(std::forward<HeadersT>(value));
55 return *this;
56 }
57 template <typename HeadersT = HttpGatewayRouteHeader>
58 HttpGatewayRouteMatch& AddHeaders(HeadersT&& value) {
59 m_headersHasBeenSet = true;
60 m_headers.emplace_back(std::forward<HeadersT>(value));
61 return *this;
62 }
64
66
69 inline const GatewayRouteHostnameMatch& GetHostname() const { return m_hostname; }
70 inline bool HostnameHasBeenSet() const { return m_hostnameHasBeenSet; }
71 template <typename HostnameT = GatewayRouteHostnameMatch>
72 void SetHostname(HostnameT&& value) {
73 m_hostnameHasBeenSet = true;
74 m_hostname = std::forward<HostnameT>(value);
75 }
76 template <typename HostnameT = GatewayRouteHostnameMatch>
77 HttpGatewayRouteMatch& WithHostname(HostnameT&& value) {
78 SetHostname(std::forward<HostnameT>(value));
79 return *this;
80 }
82
84
87 inline HttpMethod GetMethod() const { return m_method; }
88 inline bool MethodHasBeenSet() const { return m_methodHasBeenSet; }
89 inline void SetMethod(HttpMethod value) {
90 m_methodHasBeenSet = true;
91 m_method = value;
92 }
94 SetMethod(value);
95 return *this;
96 }
98
100
103 inline const HttpPathMatch& GetPath() const { return m_path; }
104 inline bool PathHasBeenSet() const { return m_pathHasBeenSet; }
105 template <typename PathT = HttpPathMatch>
106 void SetPath(PathT&& value) {
107 m_pathHasBeenSet = true;
108 m_path = std::forward<PathT>(value);
109 }
110 template <typename PathT = HttpPathMatch>
112 SetPath(std::forward<PathT>(value));
113 return *this;
114 }
116
118
121 inline int GetPort() const { return m_port; }
122 inline bool PortHasBeenSet() const { return m_portHasBeenSet; }
123 inline void SetPort(int value) {
124 m_portHasBeenSet = true;
125 m_port = value;
126 }
127 inline HttpGatewayRouteMatch& WithPort(int value) {
128 SetPort(value);
129 return *this;
130 }
132
134
142 inline const Aws::String& GetPrefix() const { return m_prefix; }
143 inline bool PrefixHasBeenSet() const { return m_prefixHasBeenSet; }
144 template <typename PrefixT = Aws::String>
145 void SetPrefix(PrefixT&& value) {
146 m_prefixHasBeenSet = true;
147 m_prefix = std::forward<PrefixT>(value);
148 }
149 template <typename PrefixT = Aws::String>
151 SetPrefix(std::forward<PrefixT>(value));
152 return *this;
153 }
155
157
160 inline const Aws::Vector<HttpQueryParameter>& GetQueryParameters() const { return m_queryParameters; }
161 inline bool QueryParametersHasBeenSet() const { return m_queryParametersHasBeenSet; }
162 template <typename QueryParametersT = Aws::Vector<HttpQueryParameter>>
163 void SetQueryParameters(QueryParametersT&& value) {
164 m_queryParametersHasBeenSet = true;
165 m_queryParameters = std::forward<QueryParametersT>(value);
166 }
167 template <typename QueryParametersT = Aws::Vector<HttpQueryParameter>>
168 HttpGatewayRouteMatch& WithQueryParameters(QueryParametersT&& value) {
169 SetQueryParameters(std::forward<QueryParametersT>(value));
170 return *this;
171 }
172 template <typename QueryParametersT = HttpQueryParameter>
173 HttpGatewayRouteMatch& AddQueryParameters(QueryParametersT&& value) {
174 m_queryParametersHasBeenSet = true;
175 m_queryParameters.emplace_back(std::forward<QueryParametersT>(value));
176 return *this;
177 }
179 private:
181
182 GatewayRouteHostnameMatch m_hostname;
183
185
186 HttpPathMatch m_path;
187
188 int m_port{0};
189
190 Aws::String m_prefix;
191
192 Aws::Vector<HttpQueryParameter> m_queryParameters;
193 bool m_headersHasBeenSet = false;
194 bool m_hostnameHasBeenSet = false;
195 bool m_methodHasBeenSet = false;
196 bool m_pathHasBeenSet = false;
197 bool m_portHasBeenSet = false;
198 bool m_prefixHasBeenSet = false;
199 bool m_queryParametersHasBeenSet = false;
200};
201
202} // namespace Model
203} // namespace AppMesh
204} // namespace Aws
HttpGatewayRouteMatch & WithPrefix(PrefixT &&value)
HttpGatewayRouteMatch & WithQueryParameters(QueryParametersT &&value)
HttpGatewayRouteMatch & WithHeaders(HeadersT &&value)
const GatewayRouteHostnameMatch & GetHostname() const
void SetQueryParameters(QueryParametersT &&value)
AWS_APPMESH_API HttpGatewayRouteMatch & operator=(Aws::Utils::Json::JsonView jsonValue)
HttpGatewayRouteMatch & WithHostname(HostnameT &&value)
HttpGatewayRouteMatch & WithPath(PathT &&value)
const Aws::Vector< HttpGatewayRouteHeader > & GetHeaders() const
AWS_APPMESH_API HttpGatewayRouteMatch(Aws::Utils::Json::JsonView jsonValue)
HttpGatewayRouteMatch & AddQueryParameters(QueryParametersT &&value)
AWS_APPMESH_API HttpGatewayRouteMatch()=default
const Aws::Vector< HttpQueryParameter > & GetQueryParameters() const
HttpGatewayRouteMatch & AddHeaders(HeadersT &&value)
HttpGatewayRouteMatch & WithPort(int value)
AWS_APPMESH_API Aws::Utils::Json::JsonValue Jsonize() const
HttpGatewayRouteMatch & WithMethod(HttpMethod value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue