AWS SDK for C++

AWS SDK for C++ Version 1.11.768

Loading...
Searching...
No Matches
PutRestApiRequest.h
1
6#pragma once
7#include <aws/apigateway/APIGatewayRequest.h>
8#include <aws/apigateway/APIGateway_EXPORTS.h>
9#include <aws/apigateway/model/PutMode.h>
10#include <aws/core/utils/Array.h>
11#include <aws/core/utils/memory/stl/AWSMap.h>
12#include <aws/core/utils/memory/stl/AWSString.h>
13
14#include <utility>
15
16namespace Aws {
17namespace Http {
18class URI;
19} // namespace Http
20namespace APIGateway {
21namespace Model {
22
30 public:
31 AWS_APIGATEWAY_API PutRestApiRequest() = default;
32
33 // Service request name is the Operation name which will send this request out,
34 // each operation should has unique request name, so that we can get operation's name from this request.
35 // Note: this is not true for response, multiple operations may have the same response name,
36 // so we can not get operation's name from response.
37 inline virtual const char* GetServiceRequestName() const override { return "PutRestApi"; }
38
39 AWS_APIGATEWAY_API void AddQueryStringParameters(Aws::Http::URI& uri) const override;
40
42
45 inline const Aws::String& GetRestApiId() const { return m_restApiId; }
46 inline bool RestApiIdHasBeenSet() const { return m_restApiIdHasBeenSet; }
47 template <typename RestApiIdT = Aws::String>
48 void SetRestApiId(RestApiIdT&& value) {
49 m_restApiIdHasBeenSet = true;
50 m_restApiId = std::forward<RestApiIdT>(value);
51 }
52 template <typename RestApiIdT = Aws::String>
53 PutRestApiRequest& WithRestApiId(RestApiIdT&& value) {
54 SetRestApiId(std::forward<RestApiIdT>(value));
55 return *this;
56 }
58
60
64 inline PutMode GetMode() const { return m_mode; }
65 inline bool ModeHasBeenSet() const { return m_modeHasBeenSet; }
66 inline void SetMode(PutMode value) {
67 m_modeHasBeenSet = true;
68 m_mode = value;
69 }
71 SetMode(value);
72 return *this;
73 }
75
77
82 inline bool GetFailOnWarnings() const { return m_failOnWarnings; }
83 inline bool FailOnWarningsHasBeenSet() const { return m_failOnWarningsHasBeenSet; }
84 inline void SetFailOnWarnings(bool value) {
85 m_failOnWarningsHasBeenSet = true;
86 m_failOnWarnings = value;
87 }
89 SetFailOnWarnings(value);
90 return *this;
91 }
93
95
102 inline const Aws::Map<Aws::String, Aws::String>& GetParameters() const { return m_parameters; }
103 inline bool ParametersHasBeenSet() const { return m_parametersHasBeenSet; }
104 template <typename ParametersT = Aws::Map<Aws::String, Aws::String>>
105 void SetParameters(ParametersT&& value) {
106 m_parametersHasBeenSet = true;
107 m_parameters = std::forward<ParametersT>(value);
108 }
109 template <typename ParametersT = Aws::Map<Aws::String, Aws::String>>
110 PutRestApiRequest& WithParameters(ParametersT&& value) {
111 SetParameters(std::forward<ParametersT>(value));
112 return *this;
113 }
114 template <typename ParametersKeyT = Aws::String, typename ParametersValueT = Aws::String>
115 PutRestApiRequest& AddParameters(ParametersKeyT&& key, ParametersValueT&& value) {
116 m_parametersHasBeenSet = true;
117 m_parameters.emplace(std::forward<ParametersKeyT>(key), std::forward<ParametersValueT>(value));
118 return *this;
119 }
121 private:
122 Aws::String m_restApiId;
123
125
126 bool m_failOnWarnings{false};
127
129
130 bool m_restApiIdHasBeenSet = false;
131 bool m_modeHasBeenSet = false;
132 bool m_failOnWarningsHasBeenSet = false;
133 bool m_parametersHasBeenSet = false;
134};
135
136} // namespace Model
137} // namespace APIGateway
138} // namespace Aws
PutRestApiRequest & WithParameters(ParametersT &&value)
const Aws::Map< Aws::String, Aws::String > & GetParameters() const
PutRestApiRequest & WithFailOnWarnings(bool value)
PutRestApiRequest & AddParameters(ParametersKeyT &&key, ParametersValueT &&value)
PutRestApiRequest & WithRestApiId(RestApiIdT &&value)
AWS_APIGATEWAY_API PutRestApiRequest()=default
AWS_APIGATEWAY_API void AddQueryStringParameters(Aws::Http::URI &uri) const override
PutRestApiRequest & WithMode(PutMode value)
virtual const char * GetServiceRequestName() const override
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String