Cocoon API: Interface Cache

org.apache.cocoon.cache
Interface Cache

All Superinterfaces:
Actor
All Known Implementing Classes:
CocoonCache, NoCache

public interface Cache
extends Actor

The interface that all caching implementations must adhere to.

Version:
$Revision: 1.7 $Date: 2000/11/20 01:43:52 $
Author:
Stefano Mazzocchi

Method Summary
 void flush()
          Flushes the cache and forces an additional cache cleanup.
 long getLastModified(javax.servlet.http.HttpServletRequest request)
          Get the time that this request was added to the cache.
 Page getPage(javax.servlet.http.HttpServletRequest request)
          It returns null if no page is available.
 void setPage(Page page, javax.servlet.http.HttpServletRequest request)
          Sets the page into the cache system using data from the request object for indexing.
 
Methods inherited from interface org.apache.cocoon.framework.Actor
init
 

Method Detail

getPage

public Page getPage(javax.servlet.http.HttpServletRequest request)
It returns null if no page is available.

setPage

public void setPage(Page page,
                    javax.servlet.http.HttpServletRequest request)
Sets the page into the cache system using data from the request object for indexing.

getLastModified

public long getLastModified(javax.servlet.http.HttpServletRequest request)
Get the time that this request was added to the cache. If the request is not in the cache, just returns -1.

flush

public void flush()
Flushes the cache and forces an additional cache cleanup. This is normally used when the system requires additional memory.


Copyright © 1999-2001 Apache Software Foundation. All Rights Reserved.