AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
Service.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/servicediscovery/ServiceDiscovery_EXPORTS.h>
10#include <aws/servicediscovery/model/DnsConfig.h>
11#include <aws/servicediscovery/model/HealthCheckConfig.h>
12#include <aws/servicediscovery/model/HealthCheckCustomConfig.h>
13#include <aws/servicediscovery/model/ServiceType.h>
14
15#include <utility>
16
17namespace Aws {
18namespace Utils {
19namespace Json {
20class JsonValue;
21class JsonView;
22} // namespace Json
23} // namespace Utils
24namespace ServiceDiscovery {
25namespace Model {
26
33class Service {
34 public:
35 AWS_SERVICEDISCOVERY_API Service() = default;
36 AWS_SERVICEDISCOVERY_API Service(Aws::Utils::Json::JsonView jsonValue);
37 AWS_SERVICEDISCOVERY_API Service& operator=(Aws::Utils::Json::JsonView jsonValue);
38 AWS_SERVICEDISCOVERY_API Aws::Utils::Json::JsonValue Jsonize() const;
39
41
44 inline const Aws::String& GetId() const { return m_id; }
45 inline bool IdHasBeenSet() const { return m_idHasBeenSet; }
46 template <typename IdT = Aws::String>
47 void SetId(IdT&& value) {
48 m_idHasBeenSet = true;
49 m_id = std::forward<IdT>(value);
50 }
51 template <typename IdT = Aws::String>
52 Service& WithId(IdT&& value) {
53 SetId(std::forward<IdT>(value));
54 return *this;
55 }
57
59
63 inline const Aws::String& GetArn() const { return m_arn; }
64 inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; }
65 template <typename ArnT = Aws::String>
66 void SetArn(ArnT&& value) {
67 m_arnHasBeenSet = true;
68 m_arn = std::forward<ArnT>(value);
69 }
70 template <typename ArnT = Aws::String>
71 Service& WithArn(ArnT&& value) {
72 SetArn(std::forward<ArnT>(value));
73 return *this;
74 }
76
78
86 inline const Aws::String& GetResourceOwner() const { return m_resourceOwner; }
87 inline bool ResourceOwnerHasBeenSet() const { return m_resourceOwnerHasBeenSet; }
88 template <typename ResourceOwnerT = Aws::String>
89 void SetResourceOwner(ResourceOwnerT&& value) {
90 m_resourceOwnerHasBeenSet = true;
91 m_resourceOwner = std::forward<ResourceOwnerT>(value);
92 }
93 template <typename ResourceOwnerT = Aws::String>
94 Service& WithResourceOwner(ResourceOwnerT&& value) {
95 SetResourceOwner(std::forward<ResourceOwnerT>(value));
96 return *this;
97 }
99
101
104 inline const Aws::String& GetName() const { return m_name; }
105 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
106 template <typename NameT = Aws::String>
107 void SetName(NameT&& value) {
108 m_nameHasBeenSet = true;
109 m_name = std::forward<NameT>(value);
110 }
111 template <typename NameT = Aws::String>
112 Service& WithName(NameT&& value) {
113 SetName(std::forward<NameT>(value));
114 return *this;
115 }
117
119
122 inline const Aws::String& GetNamespaceId() const { return m_namespaceId; }
123 inline bool NamespaceIdHasBeenSet() const { return m_namespaceIdHasBeenSet; }
124 template <typename NamespaceIdT = Aws::String>
125 void SetNamespaceId(NamespaceIdT&& value) {
126 m_namespaceIdHasBeenSet = true;
127 m_namespaceId = std::forward<NamespaceIdT>(value);
128 }
129 template <typename NamespaceIdT = Aws::String>
130 Service& WithNamespaceId(NamespaceIdT&& value) {
131 SetNamespaceId(std::forward<NamespaceIdT>(value));
132 return *this;
133 }
135
137
140 inline const Aws::String& GetDescription() const { return m_description; }
141 inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; }
142 template <typename DescriptionT = Aws::String>
143 void SetDescription(DescriptionT&& value) {
144 m_descriptionHasBeenSet = true;
145 m_description = std::forward<DescriptionT>(value);
146 }
147 template <typename DescriptionT = Aws::String>
148 Service& WithDescription(DescriptionT&& value) {
149 SetDescription(std::forward<DescriptionT>(value));
150 return *this;
151 }
153
155
161 inline int GetInstanceCount() const { return m_instanceCount; }
162 inline bool InstanceCountHasBeenSet() const { return m_instanceCountHasBeenSet; }
163 inline void SetInstanceCount(int value) {
164 m_instanceCountHasBeenSet = true;
165 m_instanceCount = value;
166 }
167 inline Service& WithInstanceCount(int value) {
168 SetInstanceCount(value);
169 return *this;
170 }
172
174
180 inline const DnsConfig& GetDnsConfig() const { return m_dnsConfig; }
181 inline bool DnsConfigHasBeenSet() const { return m_dnsConfigHasBeenSet; }
182 template <typename DnsConfigT = DnsConfig>
183 void SetDnsConfig(DnsConfigT&& value) {
184 m_dnsConfigHasBeenSet = true;
185 m_dnsConfig = std::forward<DnsConfigT>(value);
186 }
187 template <typename DnsConfigT = DnsConfig>
188 Service& WithDnsConfig(DnsConfigT&& value) {
189 SetDnsConfig(std::forward<DnsConfigT>(value));
190 return *this;
191 }
193
195
203 inline ServiceType GetType() const { return m_type; }
204 inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; }
205 inline void SetType(ServiceType value) {
206 m_typeHasBeenSet = true;
207 m_type = value;
208 }
209 inline Service& WithType(ServiceType value) {
210 SetType(value);
211 return *this;
212 }
214
216
224 inline const HealthCheckConfig& GetHealthCheckConfig() const { return m_healthCheckConfig; }
225 inline bool HealthCheckConfigHasBeenSet() const { return m_healthCheckConfigHasBeenSet; }
226 template <typename HealthCheckConfigT = HealthCheckConfig>
227 void SetHealthCheckConfig(HealthCheckConfigT&& value) {
228 m_healthCheckConfigHasBeenSet = true;
229 m_healthCheckConfig = std::forward<HealthCheckConfigT>(value);
230 }
231 template <typename HealthCheckConfigT = HealthCheckConfig>
232 Service& WithHealthCheckConfig(HealthCheckConfigT&& value) {
233 SetHealthCheckConfig(std::forward<HealthCheckConfigT>(value));
234 return *this;
235 }
237
239
245 inline const HealthCheckCustomConfig& GetHealthCheckCustomConfig() const { return m_healthCheckCustomConfig; }
246 inline bool HealthCheckCustomConfigHasBeenSet() const { return m_healthCheckCustomConfigHasBeenSet; }
247 template <typename HealthCheckCustomConfigT = HealthCheckCustomConfig>
248 void SetHealthCheckCustomConfig(HealthCheckCustomConfigT&& value) {
249 m_healthCheckCustomConfigHasBeenSet = true;
250 m_healthCheckCustomConfig = std::forward<HealthCheckCustomConfigT>(value);
251 }
252 template <typename HealthCheckCustomConfigT = HealthCheckCustomConfig>
253 Service& WithHealthCheckCustomConfig(HealthCheckCustomConfigT&& value) {
254 SetHealthCheckCustomConfig(std::forward<HealthCheckCustomConfigT>(value));
255 return *this;
256 }
258
260
266 inline const Aws::Utils::DateTime& GetCreateDate() const { return m_createDate; }
267 inline bool CreateDateHasBeenSet() const { return m_createDateHasBeenSet; }
268 template <typename CreateDateT = Aws::Utils::DateTime>
269 void SetCreateDate(CreateDateT&& value) {
270 m_createDateHasBeenSet = true;
271 m_createDate = std::forward<CreateDateT>(value);
272 }
273 template <typename CreateDateT = Aws::Utils::DateTime>
274 Service& WithCreateDate(CreateDateT&& value) {
275 SetCreateDate(std::forward<CreateDateT>(value));
276 return *this;
277 }
279
281
287 inline const Aws::String& GetCreatorRequestId() const { return m_creatorRequestId; }
288 inline bool CreatorRequestIdHasBeenSet() const { return m_creatorRequestIdHasBeenSet; }
289 template <typename CreatorRequestIdT = Aws::String>
290 void SetCreatorRequestId(CreatorRequestIdT&& value) {
291 m_creatorRequestIdHasBeenSet = true;
292 m_creatorRequestId = std::forward<CreatorRequestIdT>(value);
293 }
294 template <typename CreatorRequestIdT = Aws::String>
295 Service& WithCreatorRequestId(CreatorRequestIdT&& value) {
296 SetCreatorRequestId(std::forward<CreatorRequestIdT>(value));
297 return *this;
298 }
300
302
310 inline const Aws::String& GetCreatedByAccount() const { return m_createdByAccount; }
311 inline bool CreatedByAccountHasBeenSet() const { return m_createdByAccountHasBeenSet; }
312 template <typename CreatedByAccountT = Aws::String>
313 void SetCreatedByAccount(CreatedByAccountT&& value) {
314 m_createdByAccountHasBeenSet = true;
315 m_createdByAccount = std::forward<CreatedByAccountT>(value);
316 }
317 template <typename CreatedByAccountT = Aws::String>
318 Service& WithCreatedByAccount(CreatedByAccountT&& value) {
319 SetCreatedByAccount(std::forward<CreatedByAccountT>(value));
320 return *this;
321 }
323 private:
324 Aws::String m_id;
325
326 Aws::String m_arn;
327
328 Aws::String m_resourceOwner;
329
330 Aws::String m_name;
331
332 Aws::String m_namespaceId;
333
334 Aws::String m_description;
335
336 int m_instanceCount{0};
337
338 DnsConfig m_dnsConfig;
339
341
342 HealthCheckConfig m_healthCheckConfig;
343
344 HealthCheckCustomConfig m_healthCheckCustomConfig;
345
346 Aws::Utils::DateTime m_createDate{};
347
348 Aws::String m_creatorRequestId;
349
350 Aws::String m_createdByAccount;
351 bool m_idHasBeenSet = false;
352 bool m_arnHasBeenSet = false;
353 bool m_resourceOwnerHasBeenSet = false;
354 bool m_nameHasBeenSet = false;
355 bool m_namespaceIdHasBeenSet = false;
356 bool m_descriptionHasBeenSet = false;
357 bool m_instanceCountHasBeenSet = false;
358 bool m_dnsConfigHasBeenSet = false;
359 bool m_typeHasBeenSet = false;
360 bool m_healthCheckConfigHasBeenSet = false;
361 bool m_healthCheckCustomConfigHasBeenSet = false;
362 bool m_createDateHasBeenSet = false;
363 bool m_creatorRequestIdHasBeenSet = false;
364 bool m_createdByAccountHasBeenSet = false;
365};
366
367} // namespace Model
368} // namespace ServiceDiscovery
369} // namespace Aws
AWS_SERVICEDISCOVERY_API Service(Aws::Utils::Json::JsonView jsonValue)
const Aws::String & GetDescription() const
Definition Service.h:140
Service & WithCreatorRequestId(CreatorRequestIdT &&value)
Definition Service.h:295
const Aws::String & GetArn() const
Definition Service.h:63
const Aws::String & GetId() const
Definition Service.h:44
void SetHealthCheckConfig(HealthCheckConfigT &&value)
Definition Service.h:227
AWS_SERVICEDISCOVERY_API Aws::Utils::Json::JsonValue Jsonize() const
void SetCreateDate(CreateDateT &&value)
Definition Service.h:269
const Aws::String & GetName() const
Definition Service.h:104
Service & WithHealthCheckConfig(HealthCheckConfigT &&value)
Definition Service.h:232
AWS_SERVICEDISCOVERY_API Service & operator=(Aws::Utils::Json::JsonView jsonValue)
const HealthCheckCustomConfig & GetHealthCheckCustomConfig() const
Definition Service.h:245
Service & WithInstanceCount(int value)
Definition Service.h:167
void SetResourceOwner(ResourceOwnerT &&value)
Definition Service.h:89
Service & WithDescription(DescriptionT &&value)
Definition Service.h:148
Service & WithName(NameT &&value)
Definition Service.h:112
const Aws::String & GetNamespaceId() const
Definition Service.h:122
bool HealthCheckCustomConfigHasBeenSet() const
Definition Service.h:246
const Aws::Utils::DateTime & GetCreateDate() const
Definition Service.h:266
void SetCreatorRequestId(CreatorRequestIdT &&value)
Definition Service.h:290
Service & WithArn(ArnT &&value)
Definition Service.h:71
const Aws::String & GetResourceOwner() const
Definition Service.h:86
void SetDescription(DescriptionT &&value)
Definition Service.h:143
const Aws::String & GetCreatorRequestId() const
Definition Service.h:287
const Aws::String & GetCreatedByAccount() const
Definition Service.h:310
const DnsConfig & GetDnsConfig() const
Definition Service.h:180
Service & WithCreateDate(CreateDateT &&value)
Definition Service.h:274
const HealthCheckConfig & GetHealthCheckConfig() const
Definition Service.h:224
Service & WithHealthCheckCustomConfig(HealthCheckCustomConfigT &&value)
Definition Service.h:253
AWS_SERVICEDISCOVERY_API Service()=default
Service & WithDnsConfig(DnsConfigT &&value)
Definition Service.h:188
void SetDnsConfig(DnsConfigT &&value)
Definition Service.h:183
void SetType(ServiceType value)
Definition Service.h:205
Service & WithResourceOwner(ResourceOwnerT &&value)
Definition Service.h:94
Service & WithNamespaceId(NamespaceIdT &&value)
Definition Service.h:130
void SetNamespaceId(NamespaceIdT &&value)
Definition Service.h:125
void SetCreatedByAccount(CreatedByAccountT &&value)
Definition Service.h:313
Service & WithCreatedByAccount(CreatedByAccountT &&value)
Definition Service.h:318
void SetHealthCheckCustomConfig(HealthCheckCustomConfigT &&value)
Definition Service.h:248
Service & WithType(ServiceType value)
Definition Service.h:209
Service & WithId(IdT &&value)
Definition Service.h:52
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue