JavaScript is disabled on your browser.
Skip navigation links

AWS SDK for Java 1.x API Reference - 1.12.795

We announced the upcoming end-of-support for AWS SDK for Java (v1). We recommend that you migrate to AWS SDK for Java v2. For dates, additional details, and information on how to migrate, please refer to the linked announcement.
com.amazonaws.services.cloudfront.model

Class CachedMethods

  • All Implemented Interfaces:
    Serializable, Cloneable


    @Generated(value="com.amazonaws:aws-java-sdk-code-generator")
    public class CachedMethods
    extends Object
    implements Serializable, Cloneable 

    A complex type that controls whether CloudFront caches the response to requests using the specified HTTP methods. There are two choices:

    • CloudFront caches responses to GET and HEAD requests.

    • CloudFront caches responses to GET, HEAD, and OPTIONS requests.

    If you pick the second choice for your Amazon S3 Origin, you may need to forward Access-Control-Request-Method, Access-Control-Request-Headers, and Origin headers for the responses to be cached correctly.

    See Also:
    AWS API Documentation, Serialized Form
    • Constructor Detail

      • CachedMethods

        public CachedMethods()
    • Method Detail

      • setQuantity

        public void setQuantity(Integer quantity)

        The number of HTTP methods for which you want CloudFront to cache responses. Valid values are 2 (for caching responses to GET and HEAD requests) and 3 (for caching responses to GET, HEAD, and OPTIONS requests).

        Parameters:
        quantity - The number of HTTP methods for which you want CloudFront to cache responses. Valid values are 2 (for caching responses to GET and HEAD requests) and 3 (for caching responses to GET, HEAD, and OPTIONS requests).
      • getQuantity

        public Integer getQuantity()

        The number of HTTP methods for which you want CloudFront to cache responses. Valid values are 2 (for caching responses to GET and HEAD requests) and 3 (for caching responses to GET, HEAD, and OPTIONS requests).

        Returns:
        The number of HTTP methods for which you want CloudFront to cache responses. Valid values are 2 (for caching responses to GET and HEAD requests) and 3 (for caching responses to GET, HEAD, and OPTIONS requests).
      • withQuantity

        public CachedMethods withQuantity(Integer quantity)

        The number of HTTP methods for which you want CloudFront to cache responses. Valid values are 2 (for caching responses to GET and HEAD requests) and 3 (for caching responses to GET, HEAD, and OPTIONS requests).

        Parameters:
        quantity - The number of HTTP methods for which you want CloudFront to cache responses. Valid values are 2 (for caching responses to GET and HEAD requests) and 3 (for caching responses to GET, HEAD, and OPTIONS requests).
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • getItems

        public List<String> getItems()

        A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.

        Returns:
        A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.
        See Also:
        Method
      • setItems

        public void setItems(Collection<String> items)

        A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.

        Parameters:
        items - A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.
        See Also:
        Method
      • withItems

        public CachedMethods withItems(String... items)

        A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.

        NOTE: This method appends the values to the existing list (if any). Use setItems(java.util.Collection) or withItems(java.util.Collection) if you want to override the existing values.

        Parameters:
        items - A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        Method
      • withItems

        public CachedMethods withItems(Collection<String> items)

        A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.

        Parameters:
        items - A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        Method
      • withItems

        public CachedMethods withItems(Method... items)

        A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.

        Parameters:
        items - A complex type that contains the HTTP methods that you want CloudFront to cache responses to. Valid values for CachedMethods include GET, HEAD, and OPTIONS, depending on which caching option you choose. For more information, see the preceding section.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        Method
      • toString

        public String toString()
        Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
        Overrides:
        toString in class Object
        Returns:
        A string representation of this object.
        See Also:
        Object.toString()
Skip navigation links

AltStyle によって変換されたページ (->オリジナル) /