Class CfnCachePolicy.CookiesConfigProperty.Builder

java.lang.Object
software.amazon.awscdk.services.cloudfront.CfnCachePolicy.CookiesConfigProperty.Builder
All Implemented Interfaces:
software.amazon.jsii.Builder<CfnCachePolicy.CookiesConfigProperty>
Enclosing interface:
CfnCachePolicy.CookiesConfigProperty

@Stability(Stable) public static final class CfnCachePolicy.CookiesConfigProperty.Builder extends Object implements software.amazon.jsii.Builder<CfnCachePolicy.CookiesConfigProperty>
  • Constructor Details

    • Builder

      public Builder()
  • Method Details

    • cookieBehavior

      @Stability(Stable) public CfnCachePolicy.CookiesConfigProperty.Builder cookieBehavior(String cookieBehavior)
      Parameters:
      cookieBehavior - Determines whether any cookies in viewer requests are included in the cache key and in requests that CloudFront sends to the origin. This parameter is required. Valid values are:

      • none – No cookies in viewer requests are included in the cache key or in requests that CloudFront sends to the origin. Even when this field is set to none , any cookies that are listed in an OriginRequestPolicy are included in origin requests.
      • whitelist – Only the cookies in viewer requests that are listed in the CookieNames type are included in the cache key and in requests that CloudFront sends to the origin.
      • allExcept – All cookies in viewer requests are included in the cache key and in requests that CloudFront sends to the origin, except for those that are listed in the CookieNames type, which are not included.
      • all – All cookies in viewer requests are included in the cache key and in requests that CloudFront sends to the origin.
      Returns:
      this
    • cookies

      @Stability(Stable) public CfnCachePolicy.CookiesConfigProperty.Builder cookies(List<String> cookies)
      Parameters:
      cookies - Contains a list of cookie names.
      Returns:
      this
    • build

      @Stability(Stable) public CfnCachePolicy.CookiesConfigProperty build()
      Builds the configured instance.
      Specified by:
      build in interface software.amazon.jsii.Builder<CfnCachePolicy.CookiesConfigProperty>
      Returns:
      a new instance of CfnCachePolicy.CookiesConfigProperty
      Throws:
      NullPointerException - if any required attribute was not provided