/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Xml { class XmlNode; } // namespace Xml } // namespace Utils namespace CloudFront { namespace Model { /** *

A CloudFront origin access control.

See Also:

AWS * API Reference

*/ class OriginAccessControlSummary { public: AWS_CLOUDFRONT_API OriginAccessControlSummary(); AWS_CLOUDFRONT_API OriginAccessControlSummary(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_CLOUDFRONT_API OriginAccessControlSummary& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_CLOUDFRONT_API void AddToNode(Aws::Utils::Xml::XmlNode& parentNode) const; /** *

The unique identifier of the origin access control.

*/ inline const Aws::String& GetId() const{ return m_id; } /** *

The unique identifier of the origin access control.

*/ inline bool IdHasBeenSet() const { return m_idHasBeenSet; } /** *

The unique identifier of the origin access control.

*/ inline void SetId(const Aws::String& value) { m_idHasBeenSet = true; m_id = value; } /** *

The unique identifier of the origin access control.

*/ inline void SetId(Aws::String&& value) { m_idHasBeenSet = true; m_id = std::move(value); } /** *

The unique identifier of the origin access control.

*/ inline void SetId(const char* value) { m_idHasBeenSet = true; m_id.assign(value); } /** *

The unique identifier of the origin access control.

*/ inline OriginAccessControlSummary& WithId(const Aws::String& value) { SetId(value); return *this;} /** *

The unique identifier of the origin access control.

*/ inline OriginAccessControlSummary& WithId(Aws::String&& value) { SetId(std::move(value)); return *this;} /** *

The unique identifier of the origin access control.

*/ inline OriginAccessControlSummary& WithId(const char* value) { SetId(value); return *this;} /** *

A description of the origin access control.

*/ inline const Aws::String& GetDescription() const{ return m_description; } /** *

A description of the origin access control.

*/ inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; } /** *

A description of the origin access control.

*/ inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; } /** *

A description of the origin access control.

*/ inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); } /** *

A description of the origin access control.

*/ inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); } /** *

A description of the origin access control.

*/ inline OriginAccessControlSummary& WithDescription(const Aws::String& value) { SetDescription(value); return *this;} /** *

A description of the origin access control.

*/ inline OriginAccessControlSummary& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;} /** *

A description of the origin access control.

*/ inline OriginAccessControlSummary& WithDescription(const char* value) { SetDescription(value); return *this;} /** *

A unique name that identifies the origin access control.

*/ inline const Aws::String& GetName() const{ return m_name; } /** *

A unique name that identifies the origin access control.

*/ inline bool NameHasBeenSet() const { return m_nameHasBeenSet; } /** *

A unique name that identifies the origin access control.

*/ inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; } /** *

A unique name that identifies the origin access control.

*/ inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); } /** *

A unique name that identifies the origin access control.

*/ inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); } /** *

A unique name that identifies the origin access control.

*/ inline OriginAccessControlSummary& WithName(const Aws::String& value) { SetName(value); return *this;} /** *

A unique name that identifies the origin access control.

*/ inline OriginAccessControlSummary& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;} /** *

A unique name that identifies the origin access control.

*/ inline OriginAccessControlSummary& WithName(const char* value) { SetName(value); return *this;} /** *

The signing protocol of the origin access control. The signing protocol * determines how CloudFront signs (authenticates) requests. The only valid value * is sigv4.

*/ inline const OriginAccessControlSigningProtocols& GetSigningProtocol() const{ return m_signingProtocol; } /** *

The signing protocol of the origin access control. The signing protocol * determines how CloudFront signs (authenticates) requests. The only valid value * is sigv4.

*/ inline bool SigningProtocolHasBeenSet() const { return m_signingProtocolHasBeenSet; } /** *

The signing protocol of the origin access control. The signing protocol * determines how CloudFront signs (authenticates) requests. The only valid value * is sigv4.

*/ inline void SetSigningProtocol(const OriginAccessControlSigningProtocols& value) { m_signingProtocolHasBeenSet = true; m_signingProtocol = value; } /** *

The signing protocol of the origin access control. The signing protocol * determines how CloudFront signs (authenticates) requests. The only valid value * is sigv4.

*/ inline void SetSigningProtocol(OriginAccessControlSigningProtocols&& value) { m_signingProtocolHasBeenSet = true; m_signingProtocol = std::move(value); } /** *

The signing protocol of the origin access control. The signing protocol * determines how CloudFront signs (authenticates) requests. The only valid value * is sigv4.

*/ inline OriginAccessControlSummary& WithSigningProtocol(const OriginAccessControlSigningProtocols& value) { SetSigningProtocol(value); return *this;} /** *

The signing protocol of the origin access control. The signing protocol * determines how CloudFront signs (authenticates) requests. The only valid value * is sigv4.

*/ inline OriginAccessControlSummary& WithSigningProtocol(OriginAccessControlSigningProtocols&& value) { SetSigningProtocol(std::move(value)); return *this;} /** *

A value that specifies which requests CloudFront signs (adds authentication * information to). This field can have one of the following values:

  • *

    never – CloudFront doesn't sign any origin requests.

  • *
  • always – CloudFront signs all origin requests, overwriting * the Authorization header from the viewer request if necessary.

    *
  • no-override – If the viewer request doesn't contain * the Authorization header, CloudFront signs the origin request. If * the viewer request contains the Authorization header, CloudFront * doesn't sign the origin request, but instead passes along the * Authorization header that it received in the viewer request.

    *
*/ inline const OriginAccessControlSigningBehaviors& GetSigningBehavior() const{ return m_signingBehavior; } /** *

A value that specifies which requests CloudFront signs (adds authentication * information to). This field can have one of the following values:

  • *

    never – CloudFront doesn't sign any origin requests.

  • *
  • always – CloudFront signs all origin requests, overwriting * the Authorization header from the viewer request if necessary.

    *
  • no-override – If the viewer request doesn't contain * the Authorization header, CloudFront signs the origin request. If * the viewer request contains the Authorization header, CloudFront * doesn't sign the origin request, but instead passes along the * Authorization header that it received in the viewer request.

    *
*/ inline bool SigningBehaviorHasBeenSet() const { return m_signingBehaviorHasBeenSet; } /** *

A value that specifies which requests CloudFront signs (adds authentication * information to). This field can have one of the following values:

  • *

    never – CloudFront doesn't sign any origin requests.

  • *
  • always – CloudFront signs all origin requests, overwriting * the Authorization header from the viewer request if necessary.

    *
  • no-override – If the viewer request doesn't contain * the Authorization header, CloudFront signs the origin request. If * the viewer request contains the Authorization header, CloudFront * doesn't sign the origin request, but instead passes along the * Authorization header that it received in the viewer request.

    *
*/ inline void SetSigningBehavior(const OriginAccessControlSigningBehaviors& value) { m_signingBehaviorHasBeenSet = true; m_signingBehavior = value; } /** *

A value that specifies which requests CloudFront signs (adds authentication * information to). This field can have one of the following values:

  • *

    never – CloudFront doesn't sign any origin requests.

  • *
  • always – CloudFront signs all origin requests, overwriting * the Authorization header from the viewer request if necessary.

    *
  • no-override – If the viewer request doesn't contain * the Authorization header, CloudFront signs the origin request. If * the viewer request contains the Authorization header, CloudFront * doesn't sign the origin request, but instead passes along the * Authorization header that it received in the viewer request.

    *
*/ inline void SetSigningBehavior(OriginAccessControlSigningBehaviors&& value) { m_signingBehaviorHasBeenSet = true; m_signingBehavior = std::move(value); } /** *

A value that specifies which requests CloudFront signs (adds authentication * information to). This field can have one of the following values:

  • *

    never – CloudFront doesn't sign any origin requests.

  • *
  • always – CloudFront signs all origin requests, overwriting * the Authorization header from the viewer request if necessary.

    *
  • no-override – If the viewer request doesn't contain * the Authorization header, CloudFront signs the origin request. If * the viewer request contains the Authorization header, CloudFront * doesn't sign the origin request, but instead passes along the * Authorization header that it received in the viewer request.

    *
*/ inline OriginAccessControlSummary& WithSigningBehavior(const OriginAccessControlSigningBehaviors& value) { SetSigningBehavior(value); return *this;} /** *

A value that specifies which requests CloudFront signs (adds authentication * information to). This field can have one of the following values:

  • *

    never – CloudFront doesn't sign any origin requests.

  • *
  • always – CloudFront signs all origin requests, overwriting * the Authorization header from the viewer request if necessary.

    *
  • no-override – If the viewer request doesn't contain * the Authorization header, CloudFront signs the origin request. If * the viewer request contains the Authorization header, CloudFront * doesn't sign the origin request, but instead passes along the * Authorization header that it received in the viewer request.

    *
*/ inline OriginAccessControlSummary& WithSigningBehavior(OriginAccessControlSigningBehaviors&& value) { SetSigningBehavior(std::move(value)); return *this;} /** *

The type of origin that this origin access control is for.

*/ inline const OriginAccessControlOriginTypes& GetOriginAccessControlOriginType() const{ return m_originAccessControlOriginType; } /** *

The type of origin that this origin access control is for.

*/ inline bool OriginAccessControlOriginTypeHasBeenSet() const { return m_originAccessControlOriginTypeHasBeenSet; } /** *

The type of origin that this origin access control is for.

*/ inline void SetOriginAccessControlOriginType(const OriginAccessControlOriginTypes& value) { m_originAccessControlOriginTypeHasBeenSet = true; m_originAccessControlOriginType = value; } /** *

The type of origin that this origin access control is for.

*/ inline void SetOriginAccessControlOriginType(OriginAccessControlOriginTypes&& value) { m_originAccessControlOriginTypeHasBeenSet = true; m_originAccessControlOriginType = std::move(value); } /** *

The type of origin that this origin access control is for.

*/ inline OriginAccessControlSummary& WithOriginAccessControlOriginType(const OriginAccessControlOriginTypes& value) { SetOriginAccessControlOriginType(value); return *this;} /** *

The type of origin that this origin access control is for.

*/ inline OriginAccessControlSummary& WithOriginAccessControlOriginType(OriginAccessControlOriginTypes&& value) { SetOriginAccessControlOriginType(std::move(value)); return *this;} private: Aws::String m_id; bool m_idHasBeenSet = false; Aws::String m_description; bool m_descriptionHasBeenSet = false; Aws::String m_name; bool m_nameHasBeenSet = false; OriginAccessControlSigningProtocols m_signingProtocol; bool m_signingProtocolHasBeenSet = false; OriginAccessControlSigningBehaviors m_signingBehavior; bool m_signingBehaviorHasBeenSet = false; OriginAccessControlOriginTypes m_originAccessControlOriginType; bool m_originAccessControlOriginTypeHasBeenSet = false; }; } // namespace Model } // namespace CloudFront } // namespace Aws