/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include An origin. An origin is the location where content is stored, and from
* which CloudFront gets content to serve to viewers. To specify an origin: Use Use
* An Amazon S3 bucket that is configured with static
* website hosting An Elastic Load Balancing load balancer An AWS Elemental MediaPackage endpoint An AWS
* Elemental MediaStore container Any other HTTP server, running
* on an Amazon EC2 instance or any other kind of host For the current maximum number of origins that you can specify per
* distribution, see General
* Quotas on Web Distributions in the Amazon CloudFront Developer Guide
* (quotas were formerly referred to as limits).
* S3OriginConfig
to specify an Amazon S3 bucket that
* is not configured with static website hosting.CustomOriginConfig
to specify all other kinds of origins,
* including:
See Also:
AWS
* API Reference
A unique identifier for the origin. This value must be unique within the * distribution.
Use this value to specify the TargetOriginId
* in a CacheBehavior
or DefaultCacheBehavior
.
A unique identifier for the origin. This value must be unique within the * distribution.
Use this value to specify the TargetOriginId
* in a CacheBehavior
or DefaultCacheBehavior
.
A unique identifier for the origin. This value must be unique within the * distribution.
Use this value to specify the TargetOriginId
* in a CacheBehavior
or DefaultCacheBehavior
.
A unique identifier for the origin. This value must be unique within the * distribution.
Use this value to specify the TargetOriginId
* in a CacheBehavior
or DefaultCacheBehavior
.
A unique identifier for the origin. This value must be unique within the * distribution.
Use this value to specify the TargetOriginId
* in a CacheBehavior
or DefaultCacheBehavior
.
A unique identifier for the origin. This value must be unique within the * distribution.
Use this value to specify the TargetOriginId
* in a CacheBehavior
or DefaultCacheBehavior
.
A unique identifier for the origin. This value must be unique within the * distribution.
Use this value to specify the TargetOriginId
* in a CacheBehavior
or DefaultCacheBehavior
.
A unique identifier for the origin. This value must be unique within the * distribution.
Use this value to specify the TargetOriginId
* in a CacheBehavior
or DefaultCacheBehavior
.
The domain name for the origin.
For more information, see Origin * Domain Name in the Amazon CloudFront Developer Guide.
*/ inline const Aws::String& GetDomainName() const{ return m_domainName; } /** *The domain name for the origin.
For more information, see Origin * Domain Name in the Amazon CloudFront Developer Guide.
*/ inline bool DomainNameHasBeenSet() const { return m_domainNameHasBeenSet; } /** *The domain name for the origin.
For more information, see Origin * Domain Name in the Amazon CloudFront Developer Guide.
*/ inline void SetDomainName(const Aws::String& value) { m_domainNameHasBeenSet = true; m_domainName = value; } /** *The domain name for the origin.
For more information, see Origin * Domain Name in the Amazon CloudFront Developer Guide.
*/ inline void SetDomainName(Aws::String&& value) { m_domainNameHasBeenSet = true; m_domainName = std::move(value); } /** *The domain name for the origin.
For more information, see Origin * Domain Name in the Amazon CloudFront Developer Guide.
*/ inline void SetDomainName(const char* value) { m_domainNameHasBeenSet = true; m_domainName.assign(value); } /** *The domain name for the origin.
For more information, see Origin * Domain Name in the Amazon CloudFront Developer Guide.
*/ inline Origin& WithDomainName(const Aws::String& value) { SetDomainName(value); return *this;} /** *The domain name for the origin.
For more information, see Origin * Domain Name in the Amazon CloudFront Developer Guide.
*/ inline Origin& WithDomainName(Aws::String&& value) { SetDomainName(std::move(value)); return *this;} /** *The domain name for the origin.
For more information, see Origin * Domain Name in the Amazon CloudFront Developer Guide.
*/ inline Origin& WithDomainName(const char* value) { SetDomainName(value); return *this;} /** *An optional path that CloudFront appends to the origin domain name when * CloudFront requests content from the origin.
For more information, see Origin * Path in the Amazon CloudFront Developer Guide.
*/ inline const Aws::String& GetOriginPath() const{ return m_originPath; } /** *An optional path that CloudFront appends to the origin domain name when * CloudFront requests content from the origin.
For more information, see Origin * Path in the Amazon CloudFront Developer Guide.
*/ inline bool OriginPathHasBeenSet() const { return m_originPathHasBeenSet; } /** *An optional path that CloudFront appends to the origin domain name when * CloudFront requests content from the origin.
For more information, see Origin * Path in the Amazon CloudFront Developer Guide.
*/ inline void SetOriginPath(const Aws::String& value) { m_originPathHasBeenSet = true; m_originPath = value; } /** *An optional path that CloudFront appends to the origin domain name when * CloudFront requests content from the origin.
For more information, see Origin * Path in the Amazon CloudFront Developer Guide.
*/ inline void SetOriginPath(Aws::String&& value) { m_originPathHasBeenSet = true; m_originPath = std::move(value); } /** *An optional path that CloudFront appends to the origin domain name when * CloudFront requests content from the origin.
For more information, see Origin * Path in the Amazon CloudFront Developer Guide.
*/ inline void SetOriginPath(const char* value) { m_originPathHasBeenSet = true; m_originPath.assign(value); } /** *An optional path that CloudFront appends to the origin domain name when * CloudFront requests content from the origin.
For more information, see Origin * Path in the Amazon CloudFront Developer Guide.
*/ inline Origin& WithOriginPath(const Aws::String& value) { SetOriginPath(value); return *this;} /** *An optional path that CloudFront appends to the origin domain name when * CloudFront requests content from the origin.
For more information, see Origin * Path in the Amazon CloudFront Developer Guide.
*/ inline Origin& WithOriginPath(Aws::String&& value) { SetOriginPath(std::move(value)); return *this;} /** *An optional path that CloudFront appends to the origin domain name when * CloudFront requests content from the origin.
For more information, see Origin * Path in the Amazon CloudFront Developer Guide.
*/ inline Origin& WithOriginPath(const char* value) { SetOriginPath(value); return *this;} /** *A list of HTTP header names and values that CloudFront adds to the requests * that it sends to the origin.
For more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.
*/ inline const CustomHeaders& GetCustomHeaders() const{ return m_customHeaders; } /** *A list of HTTP header names and values that CloudFront adds to the requests * that it sends to the origin.
For more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.
*/ inline bool CustomHeadersHasBeenSet() const { return m_customHeadersHasBeenSet; } /** *A list of HTTP header names and values that CloudFront adds to the requests * that it sends to the origin.
For more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.
*/ inline void SetCustomHeaders(const CustomHeaders& value) { m_customHeadersHasBeenSet = true; m_customHeaders = value; } /** *A list of HTTP header names and values that CloudFront adds to the requests * that it sends to the origin.
For more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.
*/ inline void SetCustomHeaders(CustomHeaders&& value) { m_customHeadersHasBeenSet = true; m_customHeaders = std::move(value); } /** *A list of HTTP header names and values that CloudFront adds to the requests * that it sends to the origin.
For more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.
*/ inline Origin& WithCustomHeaders(const CustomHeaders& value) { SetCustomHeaders(value); return *this;} /** *A list of HTTP header names and values that CloudFront adds to the requests * that it sends to the origin.
For more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.
*/ inline Origin& WithCustomHeaders(CustomHeaders&& value) { SetCustomHeaders(std::move(value)); return *this;} /** *Use this type to specify an origin that is an Amazon S3 bucket that is not
* configured with static website hosting. To specify any other type of origin,
* including an Amazon S3 bucket that is configured with static website hosting,
* use the CustomOriginConfig
type instead.
Use this type to specify an origin that is an Amazon S3 bucket that is not
* configured with static website hosting. To specify any other type of origin,
* including an Amazon S3 bucket that is configured with static website hosting,
* use the CustomOriginConfig
type instead.
Use this type to specify an origin that is an Amazon S3 bucket that is not
* configured with static website hosting. To specify any other type of origin,
* including an Amazon S3 bucket that is configured with static website hosting,
* use the CustomOriginConfig
type instead.
Use this type to specify an origin that is an Amazon S3 bucket that is not
* configured with static website hosting. To specify any other type of origin,
* including an Amazon S3 bucket that is configured with static website hosting,
* use the CustomOriginConfig
type instead.
Use this type to specify an origin that is an Amazon S3 bucket that is not
* configured with static website hosting. To specify any other type of origin,
* including an Amazon S3 bucket that is configured with static website hosting,
* use the CustomOriginConfig
type instead.
Use this type to specify an origin that is an Amazon S3 bucket that is not
* configured with static website hosting. To specify any other type of origin,
* including an Amazon S3 bucket that is configured with static website hosting,
* use the CustomOriginConfig
type instead.
Use this type to specify an origin that is not an Amazon S3 bucket, with one
* exception. If the Amazon S3 bucket is configured with static website hosting,
* use this type. If the Amazon S3 bucket is not configured with static website
* hosting, use the S3OriginConfig
type instead.
Use this type to specify an origin that is not an Amazon S3 bucket, with one
* exception. If the Amazon S3 bucket is configured with static website hosting,
* use this type. If the Amazon S3 bucket is not configured with static website
* hosting, use the S3OriginConfig
type instead.
Use this type to specify an origin that is not an Amazon S3 bucket, with one
* exception. If the Amazon S3 bucket is configured with static website hosting,
* use this type. If the Amazon S3 bucket is not configured with static website
* hosting, use the S3OriginConfig
type instead.
Use this type to specify an origin that is not an Amazon S3 bucket, with one
* exception. If the Amazon S3 bucket is configured with static website hosting,
* use this type. If the Amazon S3 bucket is not configured with static website
* hosting, use the S3OriginConfig
type instead.
Use this type to specify an origin that is not an Amazon S3 bucket, with one
* exception. If the Amazon S3 bucket is configured with static website hosting,
* use this type. If the Amazon S3 bucket is not configured with static website
* hosting, use the S3OriginConfig
type instead.
Use this type to specify an origin that is not an Amazon S3 bucket, with one
* exception. If the Amazon S3 bucket is configured with static website hosting,
* use this type. If the Amazon S3 bucket is not configured with static website
* hosting, use the S3OriginConfig
type instead.
The number of times that CloudFront attempts to connect to the origin. The * minimum number is 1, the maximum is 3, and the default (if you don't specify * otherwise) is 3.
For a custom origin (including an Amazon S3 bucket * that's configured with static website hosting), this value also specifies the * number of times that CloudFront attempts to get a response from the origin, in * the case of an Origin * Response Timeout.
For more information, see Origin * Connection Attempts in the Amazon CloudFront Developer Guide.
*/ inline int GetConnectionAttempts() const{ return m_connectionAttempts; } /** *The number of times that CloudFront attempts to connect to the origin. The * minimum number is 1, the maximum is 3, and the default (if you don't specify * otherwise) is 3.
For a custom origin (including an Amazon S3 bucket * that's configured with static website hosting), this value also specifies the * number of times that CloudFront attempts to get a response from the origin, in * the case of an Origin * Response Timeout.
For more information, see Origin * Connection Attempts in the Amazon CloudFront Developer Guide.
*/ inline bool ConnectionAttemptsHasBeenSet() const { return m_connectionAttemptsHasBeenSet; } /** *The number of times that CloudFront attempts to connect to the origin. The * minimum number is 1, the maximum is 3, and the default (if you don't specify * otherwise) is 3.
For a custom origin (including an Amazon S3 bucket * that's configured with static website hosting), this value also specifies the * number of times that CloudFront attempts to get a response from the origin, in * the case of an Origin * Response Timeout.
For more information, see Origin * Connection Attempts in the Amazon CloudFront Developer Guide.
*/ inline void SetConnectionAttempts(int value) { m_connectionAttemptsHasBeenSet = true; m_connectionAttempts = value; } /** *The number of times that CloudFront attempts to connect to the origin. The * minimum number is 1, the maximum is 3, and the default (if you don't specify * otherwise) is 3.
For a custom origin (including an Amazon S3 bucket * that's configured with static website hosting), this value also specifies the * number of times that CloudFront attempts to get a response from the origin, in * the case of an Origin * Response Timeout.
For more information, see Origin * Connection Attempts in the Amazon CloudFront Developer Guide.
*/ inline Origin& WithConnectionAttempts(int value) { SetConnectionAttempts(value); return *this;} /** *The number of seconds that CloudFront waits when trying to establish a * connection to the origin. The minimum timeout is 1 second, the maximum is 10 * seconds, and the default (if you don't specify otherwise) is 10 seconds.
*For more information, see Origin * Connection Timeout in the Amazon CloudFront Developer Guide.
*/ inline int GetConnectionTimeout() const{ return m_connectionTimeout; } /** *The number of seconds that CloudFront waits when trying to establish a * connection to the origin. The minimum timeout is 1 second, the maximum is 10 * seconds, and the default (if you don't specify otherwise) is 10 seconds.
*For more information, see Origin * Connection Timeout in the Amazon CloudFront Developer Guide.
*/ inline bool ConnectionTimeoutHasBeenSet() const { return m_connectionTimeoutHasBeenSet; } /** *The number of seconds that CloudFront waits when trying to establish a * connection to the origin. The minimum timeout is 1 second, the maximum is 10 * seconds, and the default (if you don't specify otherwise) is 10 seconds.
*For more information, see Origin * Connection Timeout in the Amazon CloudFront Developer Guide.
*/ inline void SetConnectionTimeout(int value) { m_connectionTimeoutHasBeenSet = true; m_connectionTimeout = value; } /** *The number of seconds that CloudFront waits when trying to establish a * connection to the origin. The minimum timeout is 1 second, the maximum is 10 * seconds, and the default (if you don't specify otherwise) is 10 seconds.
*For more information, see Origin * Connection Timeout in the Amazon CloudFront Developer Guide.
*/ inline Origin& WithConnectionTimeout(int value) { SetConnectionTimeout(value); return *this;} /** *CloudFront Origin Shield. Using Origin Shield can help reduce the load on * your origin.
For more information, see Using * Origin Shield in the Amazon CloudFront Developer Guide.
*/ inline const OriginShield& GetOriginShield() const{ return m_originShield; } /** *CloudFront Origin Shield. Using Origin Shield can help reduce the load on * your origin.
For more information, see Using * Origin Shield in the Amazon CloudFront Developer Guide.
*/ inline bool OriginShieldHasBeenSet() const { return m_originShieldHasBeenSet; } /** *CloudFront Origin Shield. Using Origin Shield can help reduce the load on * your origin.
For more information, see Using * Origin Shield in the Amazon CloudFront Developer Guide.
*/ inline void SetOriginShield(const OriginShield& value) { m_originShieldHasBeenSet = true; m_originShield = value; } /** *CloudFront Origin Shield. Using Origin Shield can help reduce the load on * your origin.
For more information, see Using * Origin Shield in the Amazon CloudFront Developer Guide.
*/ inline void SetOriginShield(OriginShield&& value) { m_originShieldHasBeenSet = true; m_originShield = std::move(value); } /** *CloudFront Origin Shield. Using Origin Shield can help reduce the load on * your origin.
For more information, see Using * Origin Shield in the Amazon CloudFront Developer Guide.
*/ inline Origin& WithOriginShield(const OriginShield& value) { SetOriginShield(value); return *this;} /** *CloudFront Origin Shield. Using Origin Shield can help reduce the load on * your origin.
For more information, see Using * Origin Shield in the Amazon CloudFront Developer Guide.
*/ inline Origin& WithOriginShield(OriginShield&& value) { SetOriginShield(std::move(value)); return *this;} /** *The unique identifier of an origin access control for this origin.
For * more information, see Restricting * access to an Amazon S3 origin in the Amazon CloudFront Developer * Guide.
*/ inline const Aws::String& GetOriginAccessControlId() const{ return m_originAccessControlId; } /** *The unique identifier of an origin access control for this origin.
For * more information, see Restricting * access to an Amazon S3 origin in the Amazon CloudFront Developer * Guide.
*/ inline bool OriginAccessControlIdHasBeenSet() const { return m_originAccessControlIdHasBeenSet; } /** *The unique identifier of an origin access control for this origin.
For * more information, see Restricting * access to an Amazon S3 origin in the Amazon CloudFront Developer * Guide.
*/ inline void SetOriginAccessControlId(const Aws::String& value) { m_originAccessControlIdHasBeenSet = true; m_originAccessControlId = value; } /** *The unique identifier of an origin access control for this origin.
For * more information, see Restricting * access to an Amazon S3 origin in the Amazon CloudFront Developer * Guide.
*/ inline void SetOriginAccessControlId(Aws::String&& value) { m_originAccessControlIdHasBeenSet = true; m_originAccessControlId = std::move(value); } /** *The unique identifier of an origin access control for this origin.
For * more information, see Restricting * access to an Amazon S3 origin in the Amazon CloudFront Developer * Guide.
*/ inline void SetOriginAccessControlId(const char* value) { m_originAccessControlIdHasBeenSet = true; m_originAccessControlId.assign(value); } /** *The unique identifier of an origin access control for this origin.
For * more information, see Restricting * access to an Amazon S3 origin in the Amazon CloudFront Developer * Guide.
*/ inline Origin& WithOriginAccessControlId(const Aws::String& value) { SetOriginAccessControlId(value); return *this;} /** *The unique identifier of an origin access control for this origin.
For * more information, see Restricting * access to an Amazon S3 origin in the Amazon CloudFront Developer * Guide.
*/ inline Origin& WithOriginAccessControlId(Aws::String&& value) { SetOriginAccessControlId(std::move(value)); return *this;} /** *The unique identifier of an origin access control for this origin.
For * more information, see Restricting * access to an Amazon S3 origin in the Amazon CloudFront Developer * Guide.
*/ inline Origin& WithOriginAccessControlId(const char* value) { SetOriginAccessControlId(value); return *this;} private: Aws::String m_id; bool m_idHasBeenSet = false; Aws::String m_domainName; bool m_domainNameHasBeenSet = false; Aws::String m_originPath; bool m_originPathHasBeenSet = false; CustomHeaders m_customHeaders; bool m_customHeadersHasBeenSet = false; S3OriginConfig m_s3OriginConfig; bool m_s3OriginConfigHasBeenSet = false; CustomOriginConfig m_customOriginConfig; bool m_customOriginConfigHasBeenSet = false; int m_connectionAttempts; bool m_connectionAttemptsHasBeenSet = false; int m_connectionTimeout; bool m_connectionTimeoutHasBeenSet = false; OriginShield m_originShield; bool m_originShieldHasBeenSet = false; Aws::String m_originAccessControlId; bool m_originAccessControlIdHasBeenSet = false; }; } // namespace Model } // namespace CloudFront } // namespace Aws