com.ibm.portal.resolver.data
Enum CacheControlDataSource.CACHE_POLICY

java.lang.Object
  extended by java.lang.Enum<CacheControlDataSource.CACHE_POLICY>
      extended by com.ibm.portal.resolver.data.CacheControlDataSource.CACHE_POLICY
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<CacheControlDataSource.CACHE_POLICY>
Enclosing interface:
CacheControlDataSource

public static enum CacheControlDataSource.CACHE_POLICY
extends java.lang.Enum<CacheControlDataSource.CACHE_POLICY>

Controls how the content is cached


Enum Constant Summary
MUST_REVALIDATE
          Because a cache MAY be configured to ignore a server's specified expiration time, and because a client request MAY include a max- stale directive (which has a similar effect), the protocol also includes a mechanism for the origin server to require revalidation of a cache entry on any subsequent use.
NO_CACHE
          If the no-cache directive does not specify a field-name, then a cache MUST NOT use the response to satisfy a subsequent request without successful revalidation with the origin server.
NO_STORE
          The purpose of the no-store directive is to prevent the inadvertent release or retention of sensitive information (for example, on backup tapes).
UNDEFINED
          Indicates that the cache policy is unknown and that the server should apply a sensible default
 
Method Summary
abstract  CacheControlDataSource.CACHE_POLICY combine(CacheControlDataSource.CACHE_POLICY aPolicy)
          Combines a cache policy with an existing policy
static CacheControlDataSource.CACHE_POLICY valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static CacheControlDataSource.CACHE_POLICY[] values()
          Returns an array containing the constants of this enum type, in the order they are declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

MUST_REVALIDATE

public static final CacheControlDataSource.CACHE_POLICY MUST_REVALIDATE
Because a cache MAY be configured to ignore a server's specified expiration time, and because a client request MAY include a max- stale directive (which has a similar effect), the protocol also includes a mechanism for the origin server to require revalidation of a cache entry on any subsequent use. When the must-revalidate directive is present in a response received by a cache, that cache MUST NOT use the entry after it becomes stale to respond to a subsequent request without first revalidating it with the origin server. (I.e., the cache MUST do an end-to-end revalidation every time, if, based solely on the origin server's Expires or max-age value, the cached response is stale.)


NO_CACHE

public static final CacheControlDataSource.CACHE_POLICY NO_CACHE
If the no-cache directive does not specify a field-name, then a cache MUST NOT use the response to satisfy a subsequent request without successful revalidation with the origin server. This allows an origin server to prevent caching even by caches that have been configured to return stale responses to client requests. If the no-cache directive does specify one or more field-names, then a cache MAY use the response to satisfy a subsequent request, subject to any other restrictions on caching. However, the specified field-name(s) MUST NOT be sent in the response to a subsequent request without successful revalidation with the origin server. This allows an origin server to prevent the re-use of certain header fields in a response, while still allowing caching of the rest of the response.


NO_STORE

public static final CacheControlDataSource.CACHE_POLICY NO_STORE
The purpose of the no-store directive is to prevent the inadvertent release or retention of sensitive information (for example, on backup tapes). The no-store directive applies to the entire message, and MAY be sent either in a response or in a request. If sent in a request, a cache MUST NOT store any part of either this request or any response to it. If sent in a response, a cache MUST NOT store any part of either this response or the request that elicited it. This directive applies to both non- shared and shared caches. "MUST NOT store" in this context means that the cache MUST NOT intentionally store the information in non-volatile storage, and MUST make a best-effort attempt to remove the information from volatile storage as promptly as possible after forwarding it.


UNDEFINED

public static final CacheControlDataSource.CACHE_POLICY UNDEFINED
Indicates that the cache policy is unknown and that the server should apply a sensible default

Method Detail

values

public static CacheControlDataSource.CACHE_POLICY[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
for (CacheControlDataSource.CACHE_POLICY c : CacheControlDataSource.CACHE_POLICY.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static CacheControlDataSource.CACHE_POLICY valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
java.lang.NullPointerException - if the argument is null

combine

public abstract CacheControlDataSource.CACHE_POLICY combine(CacheControlDataSource.CACHE_POLICY aPolicy)
Combines a cache policy with an existing policy

Parameters:
aPolicy - the cache policy to combine
Returns:
the new policy