AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
Protection.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/ApplicationLayerAutomaticResponseConfiguration.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Json {
17class JsonValue;
18class JsonView;
19} // namespace Json
20} // namespace Utils
21namespace Shield {
22namespace Model {
23
31 public:
32 AWS_SHIELD_API Protection() = default;
33 AWS_SHIELD_API Protection(Aws::Utils::Json::JsonView jsonValue);
35 AWS_SHIELD_API Aws::Utils::Json::JsonValue Jsonize() const;
36
38
41 inline const Aws::String& GetId() const { return m_id; }
42 inline bool IdHasBeenSet() const { return m_idHasBeenSet; }
43 template <typename IdT = Aws::String>
44 void SetId(IdT&& value) {
45 m_idHasBeenSet = true;
46 m_id = std::forward<IdT>(value);
47 }
48 template <typename IdT = Aws::String>
49 Protection& WithId(IdT&& value) {
50 SetId(std::forward<IdT>(value));
51 return *this;
52 }
54
56
60 inline const Aws::String& GetName() const { return m_name; }
61 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
62 template <typename NameT = Aws::String>
63 void SetName(NameT&& value) {
64 m_nameHasBeenSet = true;
65 m_name = std::forward<NameT>(value);
66 }
67 template <typename NameT = Aws::String>
68 Protection& WithName(NameT&& value) {
69 SetName(std::forward<NameT>(value));
70 return *this;
71 }
73
75
79 inline const Aws::String& GetResourceArn() const { return m_resourceArn; }
80 inline bool ResourceArnHasBeenSet() const { return m_resourceArnHasBeenSet; }
81 template <typename ResourceArnT = Aws::String>
82 void SetResourceArn(ResourceArnT&& value) {
83 m_resourceArnHasBeenSet = true;
84 m_resourceArn = std::forward<ResourceArnT>(value);
85 }
86 template <typename ResourceArnT = Aws::String>
87 Protection& WithResourceArn(ResourceArnT&& value) {
88 SetResourceArn(std::forward<ResourceArnT>(value));
89 return *this;
90 }
92
94
98 inline const Aws::Vector<Aws::String>& GetHealthCheckIds() const { return m_healthCheckIds; }
99 inline bool HealthCheckIdsHasBeenSet() const { return m_healthCheckIdsHasBeenSet; }
100 template <typename HealthCheckIdsT = Aws::Vector<Aws::String>>
101 void SetHealthCheckIds(HealthCheckIdsT&& value) {
102 m_healthCheckIdsHasBeenSet = true;
103 m_healthCheckIds = std::forward<HealthCheckIdsT>(value);
104 }
105 template <typename HealthCheckIdsT = Aws::Vector<Aws::String>>
106 Protection& WithHealthCheckIds(HealthCheckIdsT&& value) {
107 SetHealthCheckIds(std::forward<HealthCheckIdsT>(value));
108 return *this;
109 }
110 template <typename HealthCheckIdsT = Aws::String>
111 Protection& AddHealthCheckIds(HealthCheckIdsT&& value) {
112 m_healthCheckIdsHasBeenSet = true;
113 m_healthCheckIds.emplace_back(std::forward<HealthCheckIdsT>(value));
114 return *this;
115 }
117
119
122 inline const Aws::String& GetProtectionArn() const { return m_protectionArn; }
123 inline bool ProtectionArnHasBeenSet() const { return m_protectionArnHasBeenSet; }
124 template <typename ProtectionArnT = Aws::String>
125 void SetProtectionArn(ProtectionArnT&& value) {
126 m_protectionArnHasBeenSet = true;
127 m_protectionArn = std::forward<ProtectionArnT>(value);
128 }
129 template <typename ProtectionArnT = Aws::String>
130 Protection& WithProtectionArn(ProtectionArnT&& value) {
131 SetProtectionArn(std::forward<ProtectionArnT>(value));
132 return *this;
133 }
135
137
144 return m_applicationLayerAutomaticResponseConfiguration;
145 }
147 return m_applicationLayerAutomaticResponseConfigurationHasBeenSet;
148 }
149 template <typename ApplicationLayerAutomaticResponseConfigurationT = ApplicationLayerAutomaticResponseConfiguration>
150 void SetApplicationLayerAutomaticResponseConfiguration(ApplicationLayerAutomaticResponseConfigurationT&& value) {
151 m_applicationLayerAutomaticResponseConfigurationHasBeenSet = true;
152 m_applicationLayerAutomaticResponseConfiguration = std::forward<ApplicationLayerAutomaticResponseConfigurationT>(value);
153 }
154 template <typename ApplicationLayerAutomaticResponseConfigurationT = ApplicationLayerAutomaticResponseConfiguration>
155 Protection& WithApplicationLayerAutomaticResponseConfiguration(ApplicationLayerAutomaticResponseConfigurationT&& value) {
156 SetApplicationLayerAutomaticResponseConfiguration(std::forward<ApplicationLayerAutomaticResponseConfigurationT>(value));
157 return *this;
158 }
160 private:
161 Aws::String m_id;
162
163 Aws::String m_name;
164
165 Aws::String m_resourceArn;
166
167 Aws::Vector<Aws::String> m_healthCheckIds;
168
169 Aws::String m_protectionArn;
170
171 ApplicationLayerAutomaticResponseConfiguration m_applicationLayerAutomaticResponseConfiguration;
172 bool m_idHasBeenSet = false;
173 bool m_nameHasBeenSet = false;
174 bool m_resourceArnHasBeenSet = false;
175 bool m_healthCheckIdsHasBeenSet = false;
176 bool m_protectionArnHasBeenSet = false;
177 bool m_applicationLayerAutomaticResponseConfigurationHasBeenSet = false;
178};
179
180} // namespace Model
181} // namespace Shield
182} // namespace Aws
const Aws::String & GetName() const
Definition Protection.h:60
Protection & WithResourceArn(ResourceArnT &&value)
Definition Protection.h:87
AWS_SHIELD_API Protection(Aws::Utils::Json::JsonView jsonValue)
const Aws::Vector< Aws::String > & GetHealthCheckIds() const
Definition Protection.h:98
bool ApplicationLayerAutomaticResponseConfigurationHasBeenSet() const
Definition Protection.h:146
void SetProtectionArn(ProtectionArnT &&value)
Definition Protection.h:125
const ApplicationLayerAutomaticResponseConfiguration & GetApplicationLayerAutomaticResponseConfiguration() const
Definition Protection.h:143
Protection & WithApplicationLayerAutomaticResponseConfiguration(ApplicationLayerAutomaticResponseConfigurationT &&value)
Definition Protection.h:155
void SetResourceArn(ResourceArnT &&value)
Definition Protection.h:82
bool HealthCheckIdsHasBeenSet() const
Definition Protection.h:99
Protection & WithProtectionArn(ProtectionArnT &&value)
Definition Protection.h:130
void SetName(NameT &&value)
Definition Protection.h:63
AWS_SHIELD_API Protection & operator=(Aws::Utils::Json::JsonView jsonValue)
Protection & WithId(IdT &&value)
Definition Protection.h:49
AWS_SHIELD_API Protection()=default
const Aws::String & GetProtectionArn() const
Definition Protection.h:122
const Aws::String & GetResourceArn() const
Definition Protection.h:79
void SetHealthCheckIds(HealthCheckIdsT &&value)
Definition Protection.h:101
Protection & AddHealthCheckIds(HealthCheckIdsT &&value)
Definition Protection.h:111
Protection & WithHealthCheckIds(HealthCheckIdsT &&value)
Definition Protection.h:106
AWS_SHIELD_API Aws::Utils::Json::JsonValue Jsonize() const
Protection & WithName(NameT &&value)
Definition Protection.h:68
const Aws::String & GetId() const
Definition Protection.h:41
void SetApplicationLayerAutomaticResponseConfiguration(ApplicationLayerAutomaticResponseConfigurationT &&value)
Definition Protection.h:150
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
std::vector< T, Aws::Allocator< T > > Vector
Aws::Utils::Json::JsonValue JsonValue