com.cc.framework.http
Class CacheControl

java.lang.Object
  extended bycom.cc.framework.http.CacheControl

public abstract class CacheControl
extends java.lang.Object

Helper class for setting the cache options of the HTTP header.

Since:
1.0
Version:
$Revision: 1.12 $
Author:
Harald Schulz

Constructor Summary
private CacheControl()
          Constructor
 
Method Summary
static void clearCache(javax.servlet.http.HttpServletResponse response)
          Clears the cache options
static void setCache(javax.servlet.http.HttpServletResponse response, boolean noCache)
          Sets the cache options
static void setCache(javax.servlet.http.HttpServletResponse response, boolean noCache, int expiration)
          Sets the cache options
static void setExpiration(javax.servlet.http.HttpServletResponse response, int expiration)
          Sets the expiration date
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CacheControl

private CacheControl()
Constructor

Method Detail

setCache

public static final void setCache(javax.servlet.http.HttpServletResponse response,
                                  boolean noCache)
Sets the cache options

Parameters:
response - the HttpServletResponse
noCache - true if the page should not be cached by the browser

setCache

public static final void setCache(javax.servlet.http.HttpServletResponse response,
                                  boolean noCache,
                                  int expiration)
Sets the cache options

Parameters:
response - the HttpServletResponse
noCache - true if the page should not be cached by the browser
expiration - the the expiration date of the page

clearCache

public static final void clearCache(javax.servlet.http.HttpServletResponse response)
Clears the cache options

Parameters:
response - the HttpServletResponse

setExpiration

public static final void setExpiration(javax.servlet.http.HttpServletResponse response,
                                       int expiration)
Sets the expiration date

Parameters:
response - the HttpServletResponse
expiration - the expiration date of the page


Copyright © 2000-2005 SCC Informationssysteme GmbH. All Rights Reserved.