AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
ProtectionGroup.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/shield/Shield_EXPORTS.h>
10#include <aws/shield/model/ProtectedResourceType.h>
11#include <aws/shield/model/ProtectionGroupAggregation.h>
12#include <aws/shield/model/ProtectionGroupPattern.h>
13
14#include <utility>
15
16namespace Aws {
17namespace Utils {
18namespace Json {
19class JsonValue;
20class JsonView;
21} // namespace Json
22} // namespace Utils
23namespace Shield {
24namespace Model {
25
34 public:
35 AWS_SHIELD_API ProtectionGroup() = default;
38 AWS_SHIELD_API Aws::Utils::Json::JsonValue Jsonize() const;
39
41
46 inline const Aws::String& GetProtectionGroupId() const { return m_protectionGroupId; }
47 inline bool ProtectionGroupIdHasBeenSet() const { return m_protectionGroupIdHasBeenSet; }
48 template <typename ProtectionGroupIdT = Aws::String>
49 void SetProtectionGroupId(ProtectionGroupIdT&& value) {
50 m_protectionGroupIdHasBeenSet = true;
51 m_protectionGroupId = std::forward<ProtectionGroupIdT>(value);
52 }
53 template <typename ProtectionGroupIdT = Aws::String>
54 ProtectionGroup& WithProtectionGroupId(ProtectionGroupIdT&& value) {
55 SetProtectionGroupId(std::forward<ProtectionGroupIdT>(value));
56 return *this;
57 }
59
61
74 inline ProtectionGroupAggregation GetAggregation() const { return m_aggregation; }
75 inline bool AggregationHasBeenSet() const { return m_aggregationHasBeenSet; }
77 m_aggregationHasBeenSet = true;
78 m_aggregation = value;
79 }
81 SetAggregation(value);
82 return *this;
83 }
85
87
93 inline ProtectionGroupPattern GetPattern() const { return m_pattern; }
94 inline bool PatternHasBeenSet() const { return m_patternHasBeenSet; }
96 m_patternHasBeenSet = true;
97 m_pattern = value;
98 }
100 SetPattern(value);
101 return *this;
102 }
104
106
112 inline ProtectedResourceType GetResourceType() const { return m_resourceType; }
113 inline bool ResourceTypeHasBeenSet() const { return m_resourceTypeHasBeenSet; }
115 m_resourceTypeHasBeenSet = true;
116 m_resourceType = value;
117 }
119 SetResourceType(value);
120 return *this;
121 }
123
125
131 inline const Aws::Vector<Aws::String>& GetMembers() const { return m_members; }
132 inline bool MembersHasBeenSet() const { return m_membersHasBeenSet; }
133 template <typename MembersT = Aws::Vector<Aws::String>>
134 void SetMembers(MembersT&& value) {
135 m_membersHasBeenSet = true;
136 m_members = std::forward<MembersT>(value);
137 }
138 template <typename MembersT = Aws::Vector<Aws::String>>
139 ProtectionGroup& WithMembers(MembersT&& value) {
140 SetMembers(std::forward<MembersT>(value));
141 return *this;
142 }
143 template <typename MembersT = Aws::String>
144 ProtectionGroup& AddMembers(MembersT&& value) {
145 m_membersHasBeenSet = true;
146 m_members.emplace_back(std::forward<MembersT>(value));
147 return *this;
148 }
150
152
155 inline const Aws::String& GetProtectionGroupArn() const { return m_protectionGroupArn; }
156 inline bool ProtectionGroupArnHasBeenSet() const { return m_protectionGroupArnHasBeenSet; }
157 template <typename ProtectionGroupArnT = Aws::String>
158 void SetProtectionGroupArn(ProtectionGroupArnT&& value) {
159 m_protectionGroupArnHasBeenSet = true;
160 m_protectionGroupArn = std::forward<ProtectionGroupArnT>(value);
161 }
162 template <typename ProtectionGroupArnT = Aws::String>
163 ProtectionGroup& WithProtectionGroupArn(ProtectionGroupArnT&& value) {
164 SetProtectionGroupArn(std::forward<ProtectionGroupArnT>(value));
165 return *this;
166 }
168 private:
169 Aws::String m_protectionGroupId;
170
172
174
176
177 Aws::Vector<Aws::String> m_members;
178
179 Aws::String m_protectionGroupArn;
180 bool m_protectionGroupIdHasBeenSet = false;
181 bool m_aggregationHasBeenSet = false;
182 bool m_patternHasBeenSet = false;
183 bool m_resourceTypeHasBeenSet = false;
184 bool m_membersHasBeenSet = false;
185 bool m_protectionGroupArnHasBeenSet = false;
186};
187
188} // namespace Model
189} // namespace Shield
190} // namespace Aws
AWS_SHIELD_API ProtectionGroup()=default
ProtectionGroup & WithPattern(ProtectionGroupPattern value)
ProtectedResourceType GetResourceType() const
void SetProtectionGroupArn(ProtectionGroupArnT &&value)
void SetResourceType(ProtectedResourceType value)
const Aws::String & GetProtectionGroupArn() const
ProtectionGroupAggregation GetAggregation() const
AWS_SHIELD_API ProtectionGroup(Aws::Utils::Json::JsonView jsonValue)
ProtectionGroup & WithProtectionGroupArn(ProtectionGroupArnT &&value)
const Aws::Vector< Aws::String > & GetMembers() const
void SetAggregation(ProtectionGroupAggregation value)
ProtectionGroup & WithAggregation(ProtectionGroupAggregation value)
ProtectionGroup & WithResourceType(ProtectedResourceType value)
const Aws::String & GetProtectionGroupId() const
void SetProtectionGroupId(ProtectionGroupIdT &&value)
ProtectionGroup & WithProtectionGroupId(ProtectionGroupIdT &&value)
AWS_SHIELD_API ProtectionGroup & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_SHIELD_API Aws::Utils::Json::JsonValue Jsonize() const
ProtectionGroupPattern GetPattern() const
ProtectionGroup & AddMembers(MembersT &&value)
ProtectionGroup & WithMembers(MembersT &&value)
void SetPattern(ProtectionGroupPattern value)
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue