AWS SDK for Go (PILOT)
API Reference

PREVIEW DOCUMENTATION - This is a preview of a new format for the AWS SDK for Go API Reference documentation. For the current AWS SDK for Go API Reference, see https://docs.aws.amazon.com/sdk-for-go/api/.

We welcome your feedback on this new version of the documentation. Send your comments to aws-sdkdocs-feedback@amazon.com.

CustomErrorResponses

import "github.com/aws/aws-sdk-go/service/cloudfront"

type CustomErrorResponses struct { Items []*CustomErrorResponse `locationNameList:"CustomErrorResponse" type:"list"` Quantity *int64 `type:"integer" required:"true"` }

A complex type that controls:

  • Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range with custom error messages before returning the response to the viewer.

  • How long CloudFront caches HTTP status codes in the 4xx and 5xx range.

For more information about custom error pages, see Customizing Error Responses (https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html) in the Amazon CloudFront Developer Guide.

Items

A complex type that controls:

  • Whether CloudFront replaces HTTP status codes in the 4xx and 5xx range with custom error messages before returning the response to the viewer.

  • How long CloudFront caches HTTP status codes in the 4xx and 5xx range.

For more information about custom error pages, see Customizing Error Responses (https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/custom-error-pages.html) in the Amazon CloudFront Developer Guide.

Quantity

Type: *int64

The number of HTTP status codes for which you want to specify a custom error page and/or a caching duration. If Quantity is 0, you can omit Items.

Quantity is a required field

Method

GoString

func (s CustomErrorResponses) GoString() string

GoString returns the string representation

SetItems

func (s *CustomErrorResponses) SetItems(v []*CustomErrorResponse) *CustomErrorResponses

SetItems sets the Items field's value.

SetQuantity

func (s *CustomErrorResponses) SetQuantity(v int64) *CustomErrorResponses

SetQuantity sets the Quantity field's value.

String

func (s CustomErrorResponses) String() string

String returns the string representation

Validate

func (s *CustomErrorResponses) Validate() error

Validate inspects the fields of the type to determine if they are valid.

On this page: