AWS SDK for C++

AWS SDK for C++ Version 1.11.744

Loading...
Searching...
No Matches
HttpRoute.h
1
6#pragma once
7#include <aws/appmesh/AppMesh_EXPORTS.h>
8#include <aws/appmesh/model/HttpRetryPolicy.h>
9#include <aws/appmesh/model/HttpRouteAction.h>
10#include <aws/appmesh/model/HttpRouteMatch.h>
11#include <aws/appmesh/model/HttpTimeout.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Json {
18class JsonValue;
19class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace AppMesh {
23namespace Model {
24
31class HttpRoute {
32 public:
33 AWS_APPMESH_API HttpRoute() = default;
34 AWS_APPMESH_API HttpRoute(Aws::Utils::Json::JsonView jsonValue);
35 AWS_APPMESH_API HttpRoute& operator=(Aws::Utils::Json::JsonView jsonValue);
36 AWS_APPMESH_API Aws::Utils::Json::JsonValue Jsonize() const;
37
39
42 inline const HttpRouteAction& GetAction() const { return m_action; }
43 inline bool ActionHasBeenSet() const { return m_actionHasBeenSet; }
44 template <typename ActionT = HttpRouteAction>
45 void SetAction(ActionT&& value) {
46 m_actionHasBeenSet = true;
47 m_action = std::forward<ActionT>(value);
48 }
49 template <typename ActionT = HttpRouteAction>
50 HttpRoute& WithAction(ActionT&& value) {
51 SetAction(std::forward<ActionT>(value));
52 return *this;
53 }
55
57
60 inline const HttpRouteMatch& GetMatch() const { return m_match; }
61 inline bool MatchHasBeenSet() const { return m_matchHasBeenSet; }
62 template <typename MatchT = HttpRouteMatch>
63 void SetMatch(MatchT&& value) {
64 m_matchHasBeenSet = true;
65 m_match = std::forward<MatchT>(value);
66 }
67 template <typename MatchT = HttpRouteMatch>
68 HttpRoute& WithMatch(MatchT&& value) {
69 SetMatch(std::forward<MatchT>(value));
70 return *this;
71 }
73
75
78 inline const HttpRetryPolicy& GetRetryPolicy() const { return m_retryPolicy; }
79 inline bool RetryPolicyHasBeenSet() const { return m_retryPolicyHasBeenSet; }
80 template <typename RetryPolicyT = HttpRetryPolicy>
81 void SetRetryPolicy(RetryPolicyT&& value) {
82 m_retryPolicyHasBeenSet = true;
83 m_retryPolicy = std::forward<RetryPolicyT>(value);
84 }
85 template <typename RetryPolicyT = HttpRetryPolicy>
86 HttpRoute& WithRetryPolicy(RetryPolicyT&& value) {
87 SetRetryPolicy(std::forward<RetryPolicyT>(value));
88 return *this;
89 }
91
93
96 inline const HttpTimeout& GetTimeout() const { return m_timeout; }
97 inline bool TimeoutHasBeenSet() const { return m_timeoutHasBeenSet; }
98 template <typename TimeoutT = HttpTimeout>
99 void SetTimeout(TimeoutT&& value) {
100 m_timeoutHasBeenSet = true;
101 m_timeout = std::forward<TimeoutT>(value);
102 }
103 template <typename TimeoutT = HttpTimeout>
104 HttpRoute& WithTimeout(TimeoutT&& value) {
105 SetTimeout(std::forward<TimeoutT>(value));
106 return *this;
107 }
109 private:
110 HttpRouteAction m_action;
111
112 HttpRouteMatch m_match;
113
114 HttpRetryPolicy m_retryPolicy;
115
116 HttpTimeout m_timeout;
117 bool m_actionHasBeenSet = false;
118 bool m_matchHasBeenSet = false;
119 bool m_retryPolicyHasBeenSet = false;
120 bool m_timeoutHasBeenSet = false;
121};
122
123} // namespace Model
124} // namespace AppMesh
125} // namespace Aws
const HttpRetryPolicy & GetRetryPolicy() const
Definition HttpRoute.h:78
void SetAction(ActionT &&value)
Definition HttpRoute.h:45
HttpRoute & WithAction(ActionT &&value)
Definition HttpRoute.h:50
const HttpTimeout & GetTimeout() const
Definition HttpRoute.h:96
const HttpRouteMatch & GetMatch() const
Definition HttpRoute.h:60
AWS_APPMESH_API HttpRoute & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_APPMESH_API HttpRoute()=default
AWS_APPMESH_API HttpRoute(Aws::Utils::Json::JsonView jsonValue)
HttpRoute & WithTimeout(TimeoutT &&value)
Definition HttpRoute.h:104
HttpRoute & WithMatch(MatchT &&value)
Definition HttpRoute.h:68
HttpRoute & WithRetryPolicy(RetryPolicyT &&value)
Definition HttpRoute.h:86
void SetTimeout(TimeoutT &&value)
Definition HttpRoute.h:99
AWS_APPMESH_API Aws::Utils::Json::JsonValue Jsonize() const
bool RetryPolicyHasBeenSet() const
Definition HttpRoute.h:79
void SetRetryPolicy(RetryPolicyT &&value)
Definition HttpRoute.h:81
void SetMatch(MatchT &&value)
Definition HttpRoute.h:63
const HttpRouteAction & GetAction() const
Definition HttpRoute.h:42
Aws::Utils::Json::JsonValue JsonValue