AWS SDK for C++

AWS SDK for C++ Version 1.11.606

Loading...
Searching...
No Matches
CreateSamplingRuleRequest.h
1
6#pragma once
7#include <aws/xray/XRay_EXPORTS.h>
8#include <aws/xray/XRayRequest.h>
9#include <aws/xray/model/SamplingRule.h>
10#include <aws/core/utils/memory/stl/AWSVector.h>
11#include <aws/xray/model/Tag.h>
12#include <utility>
13
14namespace Aws
15{
16namespace XRay
17{
18namespace Model
19{
20
24 {
25 public:
26 AWS_XRAY_API CreateSamplingRuleRequest() = default;
27
28 // Service request name is the Operation name which will send this request out,
29 // each operation should has unique request name, so that we can get operation's name from this request.
30 // Note: this is not true for response, multiple operations may have the same response name,
31 // so we can not get operation's name from response.
32 inline virtual const char* GetServiceRequestName() const override { return "CreateSamplingRule"; }
33
34 AWS_XRAY_API Aws::String SerializePayload() const override;
35
36
38
41 inline const SamplingRule& GetSamplingRule() const { return m_samplingRule; }
42 inline bool SamplingRuleHasBeenSet() const { return m_samplingRuleHasBeenSet; }
43 template<typename SamplingRuleT = SamplingRule>
44 void SetSamplingRule(SamplingRuleT&& value) { m_samplingRuleHasBeenSet = true; m_samplingRule = std::forward<SamplingRuleT>(value); }
45 template<typename SamplingRuleT = SamplingRule>
46 CreateSamplingRuleRequest& WithSamplingRule(SamplingRuleT&& value) { SetSamplingRule(std::forward<SamplingRuleT>(value)); return *this;}
48
50
64 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
65 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
66 template<typename TagsT = Aws::Vector<Tag>>
67 void SetTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags = std::forward<TagsT>(value); }
68 template<typename TagsT = Aws::Vector<Tag>>
69 CreateSamplingRuleRequest& WithTags(TagsT&& value) { SetTags(std::forward<TagsT>(value)); return *this;}
70 template<typename TagsT = Tag>
71 CreateSamplingRuleRequest& AddTags(TagsT&& value) { m_tagsHasBeenSet = true; m_tags.emplace_back(std::forward<TagsT>(value)); return *this; }
73 private:
74
75 SamplingRule m_samplingRule;
76 bool m_samplingRuleHasBeenSet = false;
77
78 Aws::Vector<Tag> m_tags;
79 bool m_tagsHasBeenSet = false;
80 };
81
82} // namespace Model
83} // namespace XRay
84} // namespace Aws
CreateSamplingRuleRequest & WithSamplingRule(SamplingRuleT &&value)
virtual const char * GetServiceRequestName() const override
CreateSamplingRuleRequest & AddTags(TagsT &&value)
AWS_XRAY_API Aws::String SerializePayload() const override
CreateSamplingRuleRequest & WithTags(TagsT &&value)
AWS_XRAY_API CreateSamplingRuleRequest()=default
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector