AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
ManagedRule.h
1
6#pragma once
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/core/utils/memory/stl/AWSVector.h>
9#include <aws/crt/cbor/Cbor.h>
10#include <aws/monitoring/CloudWatch_EXPORTS.h>
11#include <aws/monitoring/model/Tag.h>
12
13#include <utility>
14
15namespace Aws {
16namespace Utils {
17namespace Cbor {
18class CborValue;
19} // namespace Cbor
20} // namespace Utils
21namespace CloudWatch {
22namespace Model {
23
32 public:
33 AWS_CLOUDWATCH_API ManagedRule() = default;
34 AWS_CLOUDWATCH_API ManagedRule(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
35 AWS_CLOUDWATCH_API ManagedRule& operator=(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
36 AWS_CLOUDWATCH_API void CborEncode(Aws::Crt::Cbor::CborEncoder& encoder) const;
37
39
43 inline const Aws::String& GetTemplateName() const { return m_templateName; }
44 inline bool TemplateNameHasBeenSet() const { return m_templateNameHasBeenSet; }
45 template <typename TemplateNameT = Aws::String>
46 void SetTemplateName(TemplateNameT&& value) {
47 m_templateNameHasBeenSet = true;
48 m_templateName = std::forward<TemplateNameT>(value);
49 }
50 template <typename TemplateNameT = Aws::String>
51 ManagedRule& WithTemplateName(TemplateNameT&& value) {
52 SetTemplateName(std::forward<TemplateNameT>(value));
53 return *this;
54 }
56
58
62 inline const Aws::String& GetResourceARN() const { return m_resourceARN; }
63 inline bool ResourceARNHasBeenSet() const { return m_resourceARNHasBeenSet; }
64 template <typename ResourceARNT = Aws::String>
65 void SetResourceARN(ResourceARNT&& value) {
66 m_resourceARNHasBeenSet = true;
67 m_resourceARN = std::forward<ResourceARNT>(value);
68 }
69 template <typename ResourceARNT = Aws::String>
70 ManagedRule& WithResourceARN(ResourceARNT&& value) {
71 SetResourceARN(std::forward<ResourceARNT>(value));
72 return *this;
73 }
75
77
89 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
90 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
91 template <typename TagsT = Aws::Vector<Tag>>
92 void SetTags(TagsT&& value) {
93 m_tagsHasBeenSet = true;
94 m_tags = std::forward<TagsT>(value);
95 }
96 template <typename TagsT = Aws::Vector<Tag>>
97 ManagedRule& WithTags(TagsT&& value) {
98 SetTags(std::forward<TagsT>(value));
99 return *this;
100 }
101 template <typename TagsT = Tag>
102 ManagedRule& AddTags(TagsT&& value) {
103 m_tagsHasBeenSet = true;
104 m_tags.emplace_back(std::forward<TagsT>(value));
105 return *this;
106 }
108 private:
109 Aws::String m_templateName;
110
111 Aws::String m_resourceARN;
112
113 Aws::Vector<Tag> m_tags;
114 bool m_templateNameHasBeenSet = false;
115 bool m_resourceARNHasBeenSet = false;
116 bool m_tagsHasBeenSet = false;
117};
118
119} // namespace Model
120} // namespace CloudWatch
121} // namespace Aws
AWS_CLOUDWATCH_API ManagedRule & operator=(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
AWS_CLOUDWATCH_API void CborEncode(Aws::Crt::Cbor::CborEncoder &encoder) const
ManagedRule & WithTags(TagsT &&value)
Definition ManagedRule.h:97
void SetResourceARN(ResourceARNT &&value)
Definition ManagedRule.h:65
void SetTemplateName(TemplateNameT &&value)
Definition ManagedRule.h:46
ManagedRule & WithResourceARN(ResourceARNT &&value)
Definition ManagedRule.h:70
const Aws::String & GetTemplateName() const
Definition ManagedRule.h:43
AWS_CLOUDWATCH_API ManagedRule()=default
ManagedRule & WithTemplateName(TemplateNameT &&value)
Definition ManagedRule.h:51
ManagedRule & AddTags(TagsT &&value)
AWS_CLOUDWATCH_API ManagedRule(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
const Aws::String & GetResourceARN() const
Definition ManagedRule.h:62
const Aws::Vector< Tag > & GetTags() const
Definition ManagedRule.h:89
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector