AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
SamplingRuleUpdate.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSMap.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/xray/XRay_EXPORTS.h>
10#include <aws/xray/model/SamplingRateBoost.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Json {
17class JsonValue;
18class JsonView;
19} // namespace Json
20} // namespace Utils
21namespace XRay {
22namespace Model {
23
31 public:
32 AWS_XRAY_API SamplingRuleUpdate() = default;
36
38
42 inline const Aws::String& GetRuleName() const { return m_ruleName; }
43 inline bool RuleNameHasBeenSet() const { return m_ruleNameHasBeenSet; }
44 template <typename RuleNameT = Aws::String>
45 void SetRuleName(RuleNameT&& value) {
46 m_ruleNameHasBeenSet = true;
47 m_ruleName = std::forward<RuleNameT>(value);
48 }
49 template <typename RuleNameT = Aws::String>
50 SamplingRuleUpdate& WithRuleName(RuleNameT&& value) {
51 SetRuleName(std::forward<RuleNameT>(value));
52 return *this;
53 }
55
57
61 inline const Aws::String& GetRuleARN() const { return m_ruleARN; }
62 inline bool RuleARNHasBeenSet() const { return m_ruleARNHasBeenSet; }
63 template <typename RuleARNT = Aws::String>
64 void SetRuleARN(RuleARNT&& value) {
65 m_ruleARNHasBeenSet = true;
66 m_ruleARN = std::forward<RuleARNT>(value);
67 }
68 template <typename RuleARNT = Aws::String>
69 SamplingRuleUpdate& WithRuleARN(RuleARNT&& value) {
70 SetRuleARN(std::forward<RuleARNT>(value));
71 return *this;
72 }
74
76
80 inline const Aws::String& GetResourceARN() const { return m_resourceARN; }
81 inline bool ResourceARNHasBeenSet() const { return m_resourceARNHasBeenSet; }
82 template <typename ResourceARNT = Aws::String>
83 void SetResourceARN(ResourceARNT&& value) {
84 m_resourceARNHasBeenSet = true;
85 m_resourceARN = std::forward<ResourceARNT>(value);
86 }
87 template <typename ResourceARNT = Aws::String>
88 SamplingRuleUpdate& WithResourceARN(ResourceARNT&& value) {
89 SetResourceARN(std::forward<ResourceARNT>(value));
90 return *this;
91 }
93
95
98 inline int GetPriority() const { return m_priority; }
99 inline bool PriorityHasBeenSet() const { return m_priorityHasBeenSet; }
100 inline void SetPriority(int value) {
101 m_priorityHasBeenSet = true;
102 m_priority = value;
103 }
104 inline SamplingRuleUpdate& WithPriority(int value) {
105 SetPriority(value);
106 return *this;
107 }
109
111
115 inline double GetFixedRate() const { return m_fixedRate; }
116 inline bool FixedRateHasBeenSet() const { return m_fixedRateHasBeenSet; }
117 inline void SetFixedRate(double value) {
118 m_fixedRateHasBeenSet = true;
119 m_fixedRate = value;
120 }
121 inline SamplingRuleUpdate& WithFixedRate(double value) {
122 SetFixedRate(value);
123 return *this;
124 }
126
128
133 inline int GetReservoirSize() const { return m_reservoirSize; }
134 inline bool ReservoirSizeHasBeenSet() const { return m_reservoirSizeHasBeenSet; }
135 inline void SetReservoirSize(int value) {
136 m_reservoirSizeHasBeenSet = true;
137 m_reservoirSize = value;
138 }
140 SetReservoirSize(value);
141 return *this;
142 }
144
146
149 inline const Aws::String& GetHost() const { return m_host; }
150 inline bool HostHasBeenSet() const { return m_hostHasBeenSet; }
151 template <typename HostT = Aws::String>
152 void SetHost(HostT&& value) {
153 m_hostHasBeenSet = true;
154 m_host = std::forward<HostT>(value);
155 }
156 template <typename HostT = Aws::String>
157 SamplingRuleUpdate& WithHost(HostT&& value) {
158 SetHost(std::forward<HostT>(value));
159 return *this;
160 }
162
164
168 inline const Aws::String& GetServiceName() const { return m_serviceName; }
169 inline bool ServiceNameHasBeenSet() const { return m_serviceNameHasBeenSet; }
170 template <typename ServiceNameT = Aws::String>
171 void SetServiceName(ServiceNameT&& value) {
172 m_serviceNameHasBeenSet = true;
173 m_serviceName = std::forward<ServiceNameT>(value);
174 }
175 template <typename ServiceNameT = Aws::String>
176 SamplingRuleUpdate& WithServiceName(ServiceNameT&& value) {
177 SetServiceName(std::forward<ServiceNameT>(value));
178 return *this;
179 }
181
183
187 inline const Aws::String& GetServiceType() const { return m_serviceType; }
188 inline bool ServiceTypeHasBeenSet() const { return m_serviceTypeHasBeenSet; }
189 template <typename ServiceTypeT = Aws::String>
190 void SetServiceType(ServiceTypeT&& value) {
191 m_serviceTypeHasBeenSet = true;
192 m_serviceType = std::forward<ServiceTypeT>(value);
193 }
194 template <typename ServiceTypeT = Aws::String>
195 SamplingRuleUpdate& WithServiceType(ServiceTypeT&& value) {
196 SetServiceType(std::forward<ServiceTypeT>(value));
197 return *this;
198 }
200
202
205 inline const Aws::String& GetHTTPMethod() const { return m_hTTPMethod; }
206 inline bool HTTPMethodHasBeenSet() const { return m_hTTPMethodHasBeenSet; }
207 template <typename HTTPMethodT = Aws::String>
208 void SetHTTPMethod(HTTPMethodT&& value) {
209 m_hTTPMethodHasBeenSet = true;
210 m_hTTPMethod = std::forward<HTTPMethodT>(value);
211 }
212 template <typename HTTPMethodT = Aws::String>
213 SamplingRuleUpdate& WithHTTPMethod(HTTPMethodT&& value) {
214 SetHTTPMethod(std::forward<HTTPMethodT>(value));
215 return *this;
216 }
218
220
223 inline const Aws::String& GetURLPath() const { return m_uRLPath; }
224 inline bool URLPathHasBeenSet() const { return m_uRLPathHasBeenSet; }
225 template <typename URLPathT = Aws::String>
226 void SetURLPath(URLPathT&& value) {
227 m_uRLPathHasBeenSet = true;
228 m_uRLPath = std::forward<URLPathT>(value);
229 }
230 template <typename URLPathT = Aws::String>
231 SamplingRuleUpdate& WithURLPath(URLPathT&& value) {
232 SetURLPath(std::forward<URLPathT>(value));
233 return *this;
234 }
236
238
241 inline const Aws::Map<Aws::String, Aws::String>& GetAttributes() const { return m_attributes; }
242 inline bool AttributesHasBeenSet() const { return m_attributesHasBeenSet; }
243 template <typename AttributesT = Aws::Map<Aws::String, Aws::String>>
244 void SetAttributes(AttributesT&& value) {
245 m_attributesHasBeenSet = true;
246 m_attributes = std::forward<AttributesT>(value);
247 }
248 template <typename AttributesT = Aws::Map<Aws::String, Aws::String>>
249 SamplingRuleUpdate& WithAttributes(AttributesT&& value) {
250 SetAttributes(std::forward<AttributesT>(value));
251 return *this;
252 }
253 template <typename AttributesKeyT = Aws::String, typename AttributesValueT = Aws::String>
254 SamplingRuleUpdate& AddAttributes(AttributesKeyT&& key, AttributesValueT&& value) {
255 m_attributesHasBeenSet = true;
256 m_attributes.emplace(std::forward<AttributesKeyT>(key), std::forward<AttributesValueT>(value));
257 return *this;
258 }
260
262
267 inline const SamplingRateBoost& GetSamplingRateBoost() const { return m_samplingRateBoost; }
268 inline bool SamplingRateBoostHasBeenSet() const { return m_samplingRateBoostHasBeenSet; }
269 template <typename SamplingRateBoostT = SamplingRateBoost>
270 void SetSamplingRateBoost(SamplingRateBoostT&& value) {
271 m_samplingRateBoostHasBeenSet = true;
272 m_samplingRateBoost = std::forward<SamplingRateBoostT>(value);
273 }
274 template <typename SamplingRateBoostT = SamplingRateBoost>
275 SamplingRuleUpdate& WithSamplingRateBoost(SamplingRateBoostT&& value) {
276 SetSamplingRateBoost(std::forward<SamplingRateBoostT>(value));
277 return *this;
278 }
280 private:
281 Aws::String m_ruleName;
282
283 Aws::String m_ruleARN;
284
285 Aws::String m_resourceARN;
286
287 int m_priority{0};
288
289 double m_fixedRate{0.0};
290
291 int m_reservoirSize{0};
292
293 Aws::String m_host;
294
295 Aws::String m_serviceName;
296
297 Aws::String m_serviceType;
298
299 Aws::String m_hTTPMethod;
300
301 Aws::String m_uRLPath;
302
304
305 SamplingRateBoost m_samplingRateBoost;
306 bool m_ruleNameHasBeenSet = false;
307 bool m_ruleARNHasBeenSet = false;
308 bool m_resourceARNHasBeenSet = false;
309 bool m_priorityHasBeenSet = false;
310 bool m_fixedRateHasBeenSet = false;
311 bool m_reservoirSizeHasBeenSet = false;
312 bool m_hostHasBeenSet = false;
313 bool m_serviceNameHasBeenSet = false;
314 bool m_serviceTypeHasBeenSet = false;
315 bool m_hTTPMethodHasBeenSet = false;
316 bool m_uRLPathHasBeenSet = false;
317 bool m_attributesHasBeenSet = false;
318 bool m_samplingRateBoostHasBeenSet = false;
319};
320
321} // namespace Model
322} // namespace XRay
323} // namespace Aws
SamplingRuleUpdate & WithFixedRate(double value)
const Aws::String & GetServiceName() const
void SetServiceName(ServiceNameT &&value)
void SetAttributes(AttributesT &&value)
AWS_XRAY_API Aws::Utils::Json::JsonValue Jsonize() const
const Aws::String & GetHTTPMethod() const
SamplingRuleUpdate & WithHost(HostT &&value)
SamplingRuleUpdate & WithAttributes(AttributesT &&value)
const Aws::String & GetURLPath() const
void SetServiceType(ServiceTypeT &&value)
const Aws::Map< Aws::String, Aws::String > & GetAttributes() const
AWS_XRAY_API SamplingRuleUpdate & operator=(Aws::Utils::Json::JsonView jsonValue)
void SetSamplingRateBoost(SamplingRateBoostT &&value)
SamplingRuleUpdate & WithPriority(int value)
SamplingRuleUpdate & WithURLPath(URLPathT &&value)
const Aws::String & GetHost() const
AWS_XRAY_API SamplingRuleUpdate(Aws::Utils::Json::JsonView jsonValue)
AWS_XRAY_API SamplingRuleUpdate()=default
SamplingRuleUpdate & AddAttributes(AttributesKeyT &&key, AttributesValueT &&value)
const Aws::String & GetResourceARN() const
SamplingRuleUpdate & WithReservoirSize(int value)
void SetHTTPMethod(HTTPMethodT &&value)
SamplingRuleUpdate & WithRuleName(RuleNameT &&value)
SamplingRuleUpdate & WithRuleARN(RuleARNT &&value)
void SetResourceARN(ResourceARNT &&value)
SamplingRuleUpdate & WithResourceARN(ResourceARNT &&value)
SamplingRuleUpdate & WithSamplingRateBoost(SamplingRateBoostT &&value)
SamplingRuleUpdate & WithHTTPMethod(HTTPMethodT &&value)
const Aws::String & GetServiceType() const
const Aws::String & GetRuleName() const
const SamplingRateBoost & GetSamplingRateBoost() const
SamplingRuleUpdate & WithServiceType(ServiceTypeT &&value)
SamplingRuleUpdate & WithServiceName(ServiceNameT &&value)
const Aws::String & GetRuleARN() const
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
Aws::Utils::Json::JsonValue JsonValue