AWS SDK for C++

AWS SDK for C++ Version 1.11.716

Loading...
Searching...
No Matches
LightsailDistribution.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/lightsail/Lightsail_EXPORTS.h>
11#include <aws/lightsail/model/CacheBehavior.h>
12#include <aws/lightsail/model/CacheBehaviorPerPath.h>
13#include <aws/lightsail/model/CacheSettings.h>
14#include <aws/lightsail/model/IpAddressType.h>
15#include <aws/lightsail/model/Origin.h>
16#include <aws/lightsail/model/ResourceLocation.h>
17#include <aws/lightsail/model/ResourceType.h>
18#include <aws/lightsail/model/Tag.h>
19
20#include <utility>
21
22namespace Aws {
23namespace Utils {
24namespace Json {
25class JsonValue;
26class JsonView;
27} // namespace Json
28} // namespace Utils
29namespace Lightsail {
30namespace Model {
31
39 public:
40 AWS_LIGHTSAIL_API LightsailDistribution() = default;
43 AWS_LIGHTSAIL_API Aws::Utils::Json::JsonValue Jsonize() const;
44
46
49 inline const Aws::String& GetName() const { return m_name; }
50 inline bool NameHasBeenSet() const { return m_nameHasBeenSet; }
51 template <typename NameT = Aws::String>
52 void SetName(NameT&& value) {
53 m_nameHasBeenSet = true;
54 m_name = std::forward<NameT>(value);
55 }
56 template <typename NameT = Aws::String>
58 SetName(std::forward<NameT>(value));
59 return *this;
60 }
62
64
67 inline const Aws::String& GetArn() const { return m_arn; }
68 inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; }
69 template <typename ArnT = Aws::String>
70 void SetArn(ArnT&& value) {
71 m_arnHasBeenSet = true;
72 m_arn = std::forward<ArnT>(value);
73 }
74 template <typename ArnT = Aws::String>
76 SetArn(std::forward<ArnT>(value));
77 return *this;
78 }
80
82
87 inline const Aws::String& GetSupportCode() const { return m_supportCode; }
88 inline bool SupportCodeHasBeenSet() const { return m_supportCodeHasBeenSet; }
89 template <typename SupportCodeT = Aws::String>
90 void SetSupportCode(SupportCodeT&& value) {
91 m_supportCodeHasBeenSet = true;
92 m_supportCode = std::forward<SupportCodeT>(value);
93 }
94 template <typename SupportCodeT = Aws::String>
95 LightsailDistribution& WithSupportCode(SupportCodeT&& value) {
96 SetSupportCode(std::forward<SupportCodeT>(value));
97 return *this;
98 }
100
102
105 inline const Aws::Utils::DateTime& GetCreatedAt() const { return m_createdAt; }
106 inline bool CreatedAtHasBeenSet() const { return m_createdAtHasBeenSet; }
107 template <typename CreatedAtT = Aws::Utils::DateTime>
108 void SetCreatedAt(CreatedAtT&& value) {
109 m_createdAtHasBeenSet = true;
110 m_createdAt = std::forward<CreatedAtT>(value);
111 }
112 template <typename CreatedAtT = Aws::Utils::DateTime>
114 SetCreatedAt(std::forward<CreatedAtT>(value));
115 return *this;
116 }
118
120
127 inline const ResourceLocation& GetLocation() const { return m_location; }
128 inline bool LocationHasBeenSet() const { return m_locationHasBeenSet; }
129 template <typename LocationT = ResourceLocation>
130 void SetLocation(LocationT&& value) {
131 m_locationHasBeenSet = true;
132 m_location = std::forward<LocationT>(value);
133 }
134 template <typename LocationT = ResourceLocation>
136 SetLocation(std::forward<LocationT>(value));
137 return *this;
138 }
140
142
145 inline ResourceType GetResourceType() const { return m_resourceType; }
146 inline bool ResourceTypeHasBeenSet() const { return m_resourceTypeHasBeenSet; }
147 inline void SetResourceType(ResourceType value) {
148 m_resourceTypeHasBeenSet = true;
149 m_resourceType = value;
150 }
152 SetResourceType(value);
153 return *this;
154 }
156
158
161 inline const Aws::Vector<Aws::String>& GetAlternativeDomainNames() const { return m_alternativeDomainNames; }
162 inline bool AlternativeDomainNamesHasBeenSet() const { return m_alternativeDomainNamesHasBeenSet; }
163 template <typename AlternativeDomainNamesT = Aws::Vector<Aws::String>>
164 void SetAlternativeDomainNames(AlternativeDomainNamesT&& value) {
165 m_alternativeDomainNamesHasBeenSet = true;
166 m_alternativeDomainNames = std::forward<AlternativeDomainNamesT>(value);
167 }
168 template <typename AlternativeDomainNamesT = Aws::Vector<Aws::String>>
169 LightsailDistribution& WithAlternativeDomainNames(AlternativeDomainNamesT&& value) {
170 SetAlternativeDomainNames(std::forward<AlternativeDomainNamesT>(value));
171 return *this;
172 }
173 template <typename AlternativeDomainNamesT = Aws::String>
174 LightsailDistribution& AddAlternativeDomainNames(AlternativeDomainNamesT&& value) {
175 m_alternativeDomainNamesHasBeenSet = true;
176 m_alternativeDomainNames.emplace_back(std::forward<AlternativeDomainNamesT>(value));
177 return *this;
178 }
180
182
185 inline const Aws::String& GetStatus() const { return m_status; }
186 inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; }
187 template <typename StatusT = Aws::String>
188 void SetStatus(StatusT&& value) {
189 m_statusHasBeenSet = true;
190 m_status = std::forward<StatusT>(value);
191 }
192 template <typename StatusT = Aws::String>
194 SetStatus(std::forward<StatusT>(value));
195 return *this;
196 }
198
200
203 inline bool GetIsEnabled() const { return m_isEnabled; }
204 inline bool IsEnabledHasBeenSet() const { return m_isEnabledHasBeenSet; }
205 inline void SetIsEnabled(bool value) {
206 m_isEnabledHasBeenSet = true;
207 m_isEnabled = value;
208 }
210 SetIsEnabled(value);
211 return *this;
212 }
214
216
219 inline const Aws::String& GetDomainName() const { return m_domainName; }
220 inline bool DomainNameHasBeenSet() const { return m_domainNameHasBeenSet; }
221 template <typename DomainNameT = Aws::String>
222 void SetDomainName(DomainNameT&& value) {
223 m_domainNameHasBeenSet = true;
224 m_domainName = std::forward<DomainNameT>(value);
225 }
226 template <typename DomainNameT = Aws::String>
227 LightsailDistribution& WithDomainName(DomainNameT&& value) {
228 SetDomainName(std::forward<DomainNameT>(value));
229 return *this;
230 }
232
234
237 inline const Aws::String& GetBundleId() const { return m_bundleId; }
238 inline bool BundleIdHasBeenSet() const { return m_bundleIdHasBeenSet; }
239 template <typename BundleIdT = Aws::String>
240 void SetBundleId(BundleIdT&& value) {
241 m_bundleIdHasBeenSet = true;
242 m_bundleId = std::forward<BundleIdT>(value);
243 }
244 template <typename BundleIdT = Aws::String>
246 SetBundleId(std::forward<BundleIdT>(value));
247 return *this;
248 }
250
252
255 inline const Aws::String& GetCertificateName() const { return m_certificateName; }
256 inline bool CertificateNameHasBeenSet() const { return m_certificateNameHasBeenSet; }
257 template <typename CertificateNameT = Aws::String>
258 void SetCertificateName(CertificateNameT&& value) {
259 m_certificateNameHasBeenSet = true;
260 m_certificateName = std::forward<CertificateNameT>(value);
261 }
262 template <typename CertificateNameT = Aws::String>
263 LightsailDistribution& WithCertificateName(CertificateNameT&& value) {
264 SetCertificateName(std::forward<CertificateNameT>(value));
265 return *this;
266 }
268
270
275 inline const Origin& GetOrigin() const { return m_origin; }
276 inline bool OriginHasBeenSet() const { return m_originHasBeenSet; }
277 template <typename OriginT = Origin>
278 void SetOrigin(OriginT&& value) {
279 m_originHasBeenSet = true;
280 m_origin = std::forward<OriginT>(value);
281 }
282 template <typename OriginT = Origin>
284 SetOrigin(std::forward<OriginT>(value));
285 return *this;
286 }
288
290
293 inline const Aws::String& GetOriginPublicDNS() const { return m_originPublicDNS; }
294 inline bool OriginPublicDNSHasBeenSet() const { return m_originPublicDNSHasBeenSet; }
295 template <typename OriginPublicDNST = Aws::String>
296 void SetOriginPublicDNS(OriginPublicDNST&& value) {
297 m_originPublicDNSHasBeenSet = true;
298 m_originPublicDNS = std::forward<OriginPublicDNST>(value);
299 }
300 template <typename OriginPublicDNST = Aws::String>
301 LightsailDistribution& WithOriginPublicDNS(OriginPublicDNST&& value) {
302 SetOriginPublicDNS(std::forward<OriginPublicDNST>(value));
303 return *this;
304 }
306
308
311 inline const CacheBehavior& GetDefaultCacheBehavior() const { return m_defaultCacheBehavior; }
312 inline bool DefaultCacheBehaviorHasBeenSet() const { return m_defaultCacheBehaviorHasBeenSet; }
313 template <typename DefaultCacheBehaviorT = CacheBehavior>
314 void SetDefaultCacheBehavior(DefaultCacheBehaviorT&& value) {
315 m_defaultCacheBehaviorHasBeenSet = true;
316 m_defaultCacheBehavior = std::forward<DefaultCacheBehaviorT>(value);
317 }
318 template <typename DefaultCacheBehaviorT = CacheBehavior>
319 LightsailDistribution& WithDefaultCacheBehavior(DefaultCacheBehaviorT&& value) {
320 SetDefaultCacheBehavior(std::forward<DefaultCacheBehaviorT>(value));
321 return *this;
322 }
324
326
329 inline const CacheSettings& GetCacheBehaviorSettings() const { return m_cacheBehaviorSettings; }
330 inline bool CacheBehaviorSettingsHasBeenSet() const { return m_cacheBehaviorSettingsHasBeenSet; }
331 template <typename CacheBehaviorSettingsT = CacheSettings>
332 void SetCacheBehaviorSettings(CacheBehaviorSettingsT&& value) {
333 m_cacheBehaviorSettingsHasBeenSet = true;
334 m_cacheBehaviorSettings = std::forward<CacheBehaviorSettingsT>(value);
335 }
336 template <typename CacheBehaviorSettingsT = CacheSettings>
337 LightsailDistribution& WithCacheBehaviorSettings(CacheBehaviorSettingsT&& value) {
338 SetCacheBehaviorSettings(std::forward<CacheBehaviorSettingsT>(value));
339 return *this;
340 }
342
344
348 inline const Aws::Vector<CacheBehaviorPerPath>& GetCacheBehaviors() const { return m_cacheBehaviors; }
349 inline bool CacheBehaviorsHasBeenSet() const { return m_cacheBehaviorsHasBeenSet; }
350 template <typename CacheBehaviorsT = Aws::Vector<CacheBehaviorPerPath>>
351 void SetCacheBehaviors(CacheBehaviorsT&& value) {
352 m_cacheBehaviorsHasBeenSet = true;
353 m_cacheBehaviors = std::forward<CacheBehaviorsT>(value);
354 }
355 template <typename CacheBehaviorsT = Aws::Vector<CacheBehaviorPerPath>>
356 LightsailDistribution& WithCacheBehaviors(CacheBehaviorsT&& value) {
357 SetCacheBehaviors(std::forward<CacheBehaviorsT>(value));
358 return *this;
359 }
360 template <typename CacheBehaviorsT = CacheBehaviorPerPath>
361 LightsailDistribution& AddCacheBehaviors(CacheBehaviorsT&& value) {
362 m_cacheBehaviorsHasBeenSet = true;
363 m_cacheBehaviors.emplace_back(std::forward<CacheBehaviorsT>(value));
364 return *this;
365 }
367
369
375 inline bool GetAbleToUpdateBundle() const { return m_ableToUpdateBundle; }
376 inline bool AbleToUpdateBundleHasBeenSet() const { return m_ableToUpdateBundleHasBeenSet; }
377 inline void SetAbleToUpdateBundle(bool value) {
378 m_ableToUpdateBundleHasBeenSet = true;
379 m_ableToUpdateBundle = value;
380 }
383 return *this;
384 }
386
388
393 inline IpAddressType GetIpAddressType() const { return m_ipAddressType; }
394 inline bool IpAddressTypeHasBeenSet() const { return m_ipAddressTypeHasBeenSet; }
395 inline void SetIpAddressType(IpAddressType value) {
396 m_ipAddressTypeHasBeenSet = true;
397 m_ipAddressType = value;
398 }
400 SetIpAddressType(value);
401 return *this;
402 }
404
406
412 inline const Aws::Vector<Tag>& GetTags() const { return m_tags; }
413 inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; }
414 template <typename TagsT = Aws::Vector<Tag>>
415 void SetTags(TagsT&& value) {
416 m_tagsHasBeenSet = true;
417 m_tags = std::forward<TagsT>(value);
418 }
419 template <typename TagsT = Aws::Vector<Tag>>
421 SetTags(std::forward<TagsT>(value));
422 return *this;
423 }
424 template <typename TagsT = Tag>
426 m_tagsHasBeenSet = true;
427 m_tags.emplace_back(std::forward<TagsT>(value));
428 return *this;
429 }
431
433
437 inline const Aws::String& GetViewerMinimumTlsProtocolVersion() const { return m_viewerMinimumTlsProtocolVersion; }
438 inline bool ViewerMinimumTlsProtocolVersionHasBeenSet() const { return m_viewerMinimumTlsProtocolVersionHasBeenSet; }
439 template <typename ViewerMinimumTlsProtocolVersionT = Aws::String>
440 void SetViewerMinimumTlsProtocolVersion(ViewerMinimumTlsProtocolVersionT&& value) {
441 m_viewerMinimumTlsProtocolVersionHasBeenSet = true;
442 m_viewerMinimumTlsProtocolVersion = std::forward<ViewerMinimumTlsProtocolVersionT>(value);
443 }
444 template <typename ViewerMinimumTlsProtocolVersionT = Aws::String>
445 LightsailDistribution& WithViewerMinimumTlsProtocolVersion(ViewerMinimumTlsProtocolVersionT&& value) {
446 SetViewerMinimumTlsProtocolVersion(std::forward<ViewerMinimumTlsProtocolVersionT>(value));
447 return *this;
448 }
450 private:
451 Aws::String m_name;
452
453 Aws::String m_arn;
454
455 Aws::String m_supportCode;
456
457 Aws::Utils::DateTime m_createdAt{};
458
459 ResourceLocation m_location;
460
461 ResourceType m_resourceType{ResourceType::NOT_SET};
462
463 Aws::Vector<Aws::String> m_alternativeDomainNames;
464
465 Aws::String m_status;
466
467 bool m_isEnabled{false};
468
469 Aws::String m_domainName;
470
471 Aws::String m_bundleId;
472
473 Aws::String m_certificateName;
474
475 Origin m_origin;
476
477 Aws::String m_originPublicDNS;
478
479 CacheBehavior m_defaultCacheBehavior;
480
481 CacheSettings m_cacheBehaviorSettings;
482
483 Aws::Vector<CacheBehaviorPerPath> m_cacheBehaviors;
484
485 bool m_ableToUpdateBundle{false};
486
487 IpAddressType m_ipAddressType{IpAddressType::NOT_SET};
488
489 Aws::Vector<Tag> m_tags;
490
491 Aws::String m_viewerMinimumTlsProtocolVersion;
492 bool m_nameHasBeenSet = false;
493 bool m_arnHasBeenSet = false;
494 bool m_supportCodeHasBeenSet = false;
495 bool m_createdAtHasBeenSet = false;
496 bool m_locationHasBeenSet = false;
497 bool m_resourceTypeHasBeenSet = false;
498 bool m_alternativeDomainNamesHasBeenSet = false;
499 bool m_statusHasBeenSet = false;
500 bool m_isEnabledHasBeenSet = false;
501 bool m_domainNameHasBeenSet = false;
502 bool m_bundleIdHasBeenSet = false;
503 bool m_certificateNameHasBeenSet = false;
504 bool m_originHasBeenSet = false;
505 bool m_originPublicDNSHasBeenSet = false;
506 bool m_defaultCacheBehaviorHasBeenSet = false;
507 bool m_cacheBehaviorSettingsHasBeenSet = false;
508 bool m_cacheBehaviorsHasBeenSet = false;
509 bool m_ableToUpdateBundleHasBeenSet = false;
510 bool m_ipAddressTypeHasBeenSet = false;
511 bool m_tagsHasBeenSet = false;
512 bool m_viewerMinimumTlsProtocolVersionHasBeenSet = false;
513};
514
515} // namespace Model
516} // namespace Lightsail
517} // namespace Aws
LightsailDistribution & WithDomainName(DomainNameT &&value)
LightsailDistribution & WithIsEnabled(bool value)
LightsailDistribution & WithArn(ArnT &&value)
const Aws::String & GetViewerMinimumTlsProtocolVersion() const
LightsailDistribution & WithCreatedAt(CreatedAtT &&value)
LightsailDistribution & WithOrigin(OriginT &&value)
AWS_LIGHTSAIL_API Aws::Utils::Json::JsonValue Jsonize() const
AWS_LIGHTSAIL_API LightsailDistribution & operator=(Aws::Utils::Json::JsonView jsonValue)
LightsailDistribution & WithOriginPublicDNS(OriginPublicDNST &&value)
LightsailDistribution & WithViewerMinimumTlsProtocolVersion(ViewerMinimumTlsProtocolVersionT &&value)
const Aws::Vector< CacheBehaviorPerPath > & GetCacheBehaviors() const
LightsailDistribution & WithCacheBehaviors(CacheBehaviorsT &&value)
void SetViewerMinimumTlsProtocolVersion(ViewerMinimumTlsProtocolVersionT &&value)
LightsailDistribution & WithCertificateName(CertificateNameT &&value)
LightsailDistribution & WithBundleId(BundleIdT &&value)
LightsailDistribution & AddTags(TagsT &&value)
LightsailDistribution & AddAlternativeDomainNames(AlternativeDomainNamesT &&value)
AWS_LIGHTSAIL_API LightsailDistribution()=default
LightsailDistribution & WithAlternativeDomainNames(AlternativeDomainNamesT &&value)
LightsailDistribution & WithTags(TagsT &&value)
void SetCacheBehaviorSettings(CacheBehaviorSettingsT &&value)
const Aws::Utils::DateTime & GetCreatedAt() const
LightsailDistribution & WithIpAddressType(IpAddressType value)
AWS_LIGHTSAIL_API LightsailDistribution(Aws::Utils::Json::JsonView jsonValue)
LightsailDistribution & AddCacheBehaviors(CacheBehaviorsT &&value)
const CacheBehavior & GetDefaultCacheBehavior() const
LightsailDistribution & WithName(NameT &&value)
LightsailDistribution & WithLocation(LocationT &&value)
LightsailDistribution & WithSupportCode(SupportCodeT &&value)
LightsailDistribution & WithStatus(StatusT &&value)
LightsailDistribution & WithAbleToUpdateBundle(bool value)
void SetAlternativeDomainNames(AlternativeDomainNamesT &&value)
void SetDefaultCacheBehavior(DefaultCacheBehaviorT &&value)
LightsailDistribution & WithCacheBehaviorSettings(CacheBehaviorSettingsT &&value)
const CacheSettings & GetCacheBehaviorSettings() const
const Aws::Vector< Aws::String > & GetAlternativeDomainNames() const
LightsailDistribution & WithResourceType(ResourceType value)
LightsailDistribution & WithDefaultCacheBehavior(DefaultCacheBehaviorT &&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