com.holonplatform.http

## Interface CacheControl

- All Superinterfaces:
    Serializable

      public interface CacheControl
      extends Serializable

  Representation of a HTTP Cache-Control header.
  Since:
    5.0.0

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Interface and Description
    --- | ---
    `static interface` | `CacheControl.Builder` `CacheControl` builder.

  - ### Method Summary

    All Methods Static Methods Instance Methods Abstract Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `Optional<String>` | `asHeader()` Returns the cache-control directives as HTTP header value
    `static CacheControl.Builder` | `builder()` Builder to create a `CacheControl` instance
    `long` | `getMaxAge()` Get the max-age cache control directive.
    `long` | `getSMaxAge()` Get the s-maxage cache control directive.
    `boolean` | `isMustRevalidate()` Get the must-revalidate cache control directive.
    `boolean` | `isNoCache()` Get the no-cache cache control directive.
    `boolean` | `isNoStore()` Get the no-store cache control directive.
    `boolean` | `isNoTransform()` Get the no-transform cache control directive.
    `boolean` | `isPrivate()` Get the private cache control directive.
    `boolean` | `isProxyRevalidate()` Get the proxy-revalidate cache control directive.

- - ### Method Detail

    - #### isMustRevalidate

          boolean isMustRevalidate()

      Get the must-revalidate cache control directive.
      Returns:
        true if the must-revalidate cache control directive will be included in header

    - #### isProxyRevalidate

          boolean isProxyRevalidate()

      Get the proxy-revalidate cache control directive.
      Returns:
        true if the proxy-revalidate cache control directive will be included in header

    - #### getMaxAge

          long getMaxAge()

      Get the max-age cache control directive.
      Returns:
        the value of the max-age cache control directive, -1 if the directive is disabled

    - #### getSMaxAge

          long getSMaxAge()

      Get the s-maxage cache control directive.
      Returns:
        the value of the s-maxage cache control directive, -1 if the directive is disabled

    - #### isNoCache

          boolean isNoCache()

      Get the no-cache cache control directive.
      Returns:
        true if the no-cache cache control directive will be included in header

    - #### isPrivate

          boolean isPrivate()

      Get the private cache control directive.
      Returns:
        true if the private cache control directive will be included in header

    - #### isNoTransform

          boolean isNoTransform()

      Get the no-transform cache control directive.
      Returns:
        true if the no-transform cache control directive will be included in header

    - #### isNoStore

          boolean isNoStore()

      Get the no-store cache control directive.
      Returns:
        true if the no-store cache control directive will be included in header

    - #### asHeader

          Optional<String> asHeader()

      Returns the cache-control directives as HTTP header value
      Returns:
        Cache-control directives HTTP header value

    - #### builder

          static CacheControl.Builder builder()

      Builder to create a `CacheControl` instance
      Returns:
        CacheControl builder

Copyright © 2019 The Holon Platform. All rights reserved.