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

A complex type that contains HeaderName and * HeaderValue elements, if any, for this distribution.

See * Also:

AWS * API Reference

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

The name of a header that you want CloudFront to send to your origin. For * more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.

*/ inline const Aws::String& GetHeaderName() const{ return m_headerName; } /** *

The name of a header that you want CloudFront to send to your origin. For * more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.

*/ inline bool HeaderNameHasBeenSet() const { return m_headerNameHasBeenSet; } /** *

The name of a header that you want CloudFront to send to your origin. For * more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.

*/ inline void SetHeaderName(const Aws::String& value) { m_headerNameHasBeenSet = true; m_headerName = value; } /** *

The name of a header that you want CloudFront to send to your origin. For * more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.

*/ inline void SetHeaderName(Aws::String&& value) { m_headerNameHasBeenSet = true; m_headerName = std::move(value); } /** *

The name of a header that you want CloudFront to send to your origin. For * more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.

*/ inline void SetHeaderName(const char* value) { m_headerNameHasBeenSet = true; m_headerName.assign(value); } /** *

The name of a header that you want CloudFront to send to your origin. For * more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.

*/ inline OriginCustomHeader& WithHeaderName(const Aws::String& value) { SetHeaderName(value); return *this;} /** *

The name of a header that you want CloudFront to send to your origin. For * more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.

*/ inline OriginCustomHeader& WithHeaderName(Aws::String&& value) { SetHeaderName(std::move(value)); return *this;} /** *

The name of a header that you want CloudFront to send to your origin. For * more information, see Adding * Custom Headers to Origin Requests in the Amazon CloudFront Developer * Guide.

*/ inline OriginCustomHeader& WithHeaderName(const char* value) { SetHeaderName(value); return *this;} /** *

The value for the header that you specified in the HeaderName * field.

*/ inline const Aws::String& GetHeaderValue() const{ return m_headerValue; } /** *

The value for the header that you specified in the HeaderName * field.

*/ inline bool HeaderValueHasBeenSet() const { return m_headerValueHasBeenSet; } /** *

The value for the header that you specified in the HeaderName * field.

*/ inline void SetHeaderValue(const Aws::String& value) { m_headerValueHasBeenSet = true; m_headerValue = value; } /** *

The value for the header that you specified in the HeaderName * field.

*/ inline void SetHeaderValue(Aws::String&& value) { m_headerValueHasBeenSet = true; m_headerValue = std::move(value); } /** *

The value for the header that you specified in the HeaderName * field.

*/ inline void SetHeaderValue(const char* value) { m_headerValueHasBeenSet = true; m_headerValue.assign(value); } /** *

The value for the header that you specified in the HeaderName * field.

*/ inline OriginCustomHeader& WithHeaderValue(const Aws::String& value) { SetHeaderValue(value); return *this;} /** *

The value for the header that you specified in the HeaderName * field.

*/ inline OriginCustomHeader& WithHeaderValue(Aws::String&& value) { SetHeaderValue(std::move(value)); return *this;} /** *

The value for the header that you specified in the HeaderName * field.

*/ inline OriginCustomHeader& WithHeaderValue(const char* value) { SetHeaderValue(value); return *this;} private: Aws::String m_headerName; bool m_headerNameHasBeenSet = false; Aws::String m_headerValue; bool m_headerValueHasBeenSet = false; }; } // namespace Model } // namespace CloudFront } // namespace Aws