|
J2EE1.4 SDK | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
CacheHelper interface is an user-extensible interface to customize: a) the key generation b) whether to cache the response.
| Field Summary | |
static java.lang.String |
ATTR_CACHE_MAPPED_SERVLET_NAME
|
static java.lang.String |
ATTR_CACHE_MAPPED_URL_PATTERN
|
static int |
TIMEOUT_VALUE_NOT_SET
|
| Method Summary | |
void |
destroy()
Stop the helper from active use |
java.lang.String |
getCacheKey(HttpServletRequest request)
getCacheKey: generate the key to be used to cache this request |
int |
getTimeout(HttpServletRequest request)
get timeout for the cached response. |
void |
init(ServletContext context,
java.util.Map props)
initialize the helper |
boolean |
isCacheable(HttpServletRequest request)
isCacheable: is the response to given request cachebale? |
boolean |
isRefreshNeeded(HttpServletRequest request)
isRefreshNeeded: is the response to given request be refreshed? |
| Field Detail |
public static final java.lang.String ATTR_CACHE_MAPPED_SERVLET_NAME
public static final java.lang.String ATTR_CACHE_MAPPED_URL_PATTERN
public static final int TIMEOUT_VALUE_NOT_SET
| Method Detail |
public void init(ServletContext context,
java.util.Map props)
throws java.lang.Exception
context - the web application context this helper belongs to
java.lang.Exception - if a startup error occurspublic java.lang.String getCacheKey(HttpServletRequest request)
request - incoming HttpServletRequest objectpublic boolean isCacheable(HttpServletRequest request)
request - incoming HttpServletRequest objectpublic boolean isRefreshNeeded(HttpServletRequest request)
request - incoming HttpServletRequest objectpublic int getTimeout(HttpServletRequest request)
request - incoming HttpServletRequest object
public void destroy()
throws java.lang.Exception
java.lang.Exception - if an error occurs
|
J2EE1.4 SDK | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Copyright 2003 Sun Microsystems, Inc. All rights reserved.