|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.caucho.server.dispatch.AbstractFilterChain
com.caucho.server.cache.AbstractCacheFilterChain
com.caucho.server.cache.CacheFilterChain
public class CacheFilterChain
Represents the final servlet in a filter chain.
| Constructor Summary | |
|---|---|
CacheFilterChain(Cache cache,
FilterChain next,
WebApp webApp)
Create the filter chain servlet. |
|
CacheFilterChain(FilterChain next,
WebApp webApp)
Create the filter chain servlet. |
|
| Method Summary | |
|---|---|
void |
clearExpires()
Clears the expires timers |
void |
doFilter(ServletRequest request,
ServletResponse response)
Handles caching for the filter. |
boolean |
doResume(ServletRequest request,
ServletResponse response)
Resumes the request. |
boolean |
fillFromCache(CauchoRequest req,
AbstractHttpResponse response,
AbstractCacheEntry abstractEntry,
boolean isTop)
fillFromCache is called when the client needs the entire result, and the result is already in the cache. |
void |
finishCaching(AbstractCacheEntry requestEntry)
Update the headers when the caching has finished. |
long |
getHitCount()
|
java.lang.String |
getUri()
|
WebApp |
getWebApp()
|
boolean |
isTop(boolean isTop)
True for top-level requests. |
void |
killCaching(AbstractCacheEntry loadingEntry)
Update the headers when the caching has finished. |
void |
removeEvent()
Callback when the item has been removed from the cache, usually because of an LRU event. |
void |
setTop(boolean isTop)
True for top-level requests. |
AbstractCacheEntry |
startCaching(CauchoRequest req,
AbstractHttpResponse res,
java.util.ArrayList<java.lang.String> keys,
java.util.ArrayList<java.lang.String> values,
java.lang.String contentType,
java.lang.String charEncoding,
long contentLength)
Starts the caching after the headers have been sent. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public CacheFilterChain(FilterChain next,
WebApp webApp)
public CacheFilterChain(Cache cache,
FilterChain next,
WebApp webApp)
| Method Detail |
|---|
public void setTop(boolean isTop)
public boolean isTop(boolean isTop)
public long getHitCount()
public WebApp getWebApp()
public java.lang.String getUri()
public void clearExpires()
public void doFilter(ServletRequest request,
ServletResponse response)
throws ServletException,
java.io.IOException
doFilter in interface FilterChainreq - the servlet requestres - the servlet response
ServletException
java.io.IOException
public boolean doResume(ServletRequest request,
ServletResponse response)
throws ServletException,
java.io.IOException
doResume in interface CometFilterChaindoResume in class AbstractFilterChainrequest - the servlet requestresponse - the servlet response
ServletException
java.io.IOException
public boolean fillFromCache(CauchoRequest req,
AbstractHttpResponse response,
AbstractCacheEntry abstractEntry,
boolean isTop)
throws java.io.IOException
fillFromCache in class AbstractCacheFilterChainreq - the servlet request trying to get data from the cacheresponse - the servlet response which will receive dataentry - the cache entry to useisTop - if true, the not-modified should be sent to the browser
java.io.IOException
public AbstractCacheEntry startCaching(CauchoRequest req,
AbstractHttpResponse res,
java.util.ArrayList<java.lang.String> keys,
java.util.ArrayList<java.lang.String> values,
java.lang.String contentType,
java.lang.String charEncoding,
long contentLength)
startCaching in class AbstractCacheFilterChainreq - the servlet requestreq - the servlet responsekeys - the saved header keysvalues - the saved header valuescontentType - the response content typecharEncoding - the response character encoding
public void finishCaching(AbstractCacheEntry requestEntry)
finishCaching in class AbstractCacheFilterChainokay - if true, the cache if validpublic void killCaching(AbstractCacheEntry loadingEntry)
killCaching in class AbstractCacheFilterChainokay - if true, the cache if validpublic void removeEvent()
removeEvent in interface CacheListenerpublic java.lang.String toString()
toString in class AbstractFilterChain
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||