|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.cocoon.portal.impl.AbstractComponent
org.apache.cocoon.portal.coplet.adapter.impl.AbstractCopletAdapter
org.apache.cocoon.portal.coplet.adapter.impl.URICopletAdapter
org.apache.cocoon.portal.coplet.adapter.impl.CachingURICopletAdapter
This adapter extends the URICopletAdapter
by a caching mechanism. The result of the called uri/pipeline is cached until a
CopletInstanceEvent for that coplet instance
is received.
The content can eiter be cached in the user session or globally. The default is
the user session.
| Field Summary | |
protected Cache |
cache
The cache to use for global caching. |
static String |
CACHE
The temporary attribute name for the storing the cached coplet content. |
static String |
CONFIGURATION_CACHE_GLOBAL
The configuration name for using the global cache. |
static String |
CONFIGURATION_CACHE_GLOBAL_USE_ATTRIBUTES
The configuration name for querying instance attributes to generate the key for the global cache. |
static String |
CONFIGURATION_ENABLE_CACHING
The configuration name for enabling/disabling the cache. |
static String |
CONFIGURATION_IGNORE_SIZING_EVENTS
The configuration name for ignoring sizing events to clear the cache. |
static String |
DO_NOT_CACHE
This temporary attribute can be set on the instance to not cache the current response. |
| Fields inherited from class org.apache.cocoon.portal.coplet.adapter.impl.URICopletAdapter |
resolver |
| Fields inherited from class org.apache.cocoon.portal.impl.AbstractComponent |
context, manager, portalService |
| Fields inherited from interface org.apache.cocoon.portal.coplet.adapter.CopletAdapter |
ROLE |
| Constructor Summary | |
CachingURICopletAdapter()
|
|
| Method Summary | |
void |
dispose()
|
protected String |
getCacheKey(CopletInstanceData coplet,
String uri)
Build the key for the global cache. |
void |
handleCopletInstanceEvent(CopletInstanceEvent event)
This adapter listens for CopletInstanceEvents. |
void |
inform(CopletInstanceEvent e,
PortalService service)
|
void |
service(ServiceManager manager)
|
void |
streamContent(CopletInstanceData coplet,
ContentHandler contentHandler)
Implement this and not toSAX() |
void |
streamContent(CopletInstanceData coplet,
String uri,
ContentHandler contentHandler)
|
| Methods inherited from class org.apache.cocoon.portal.coplet.adapter.impl.URICopletAdapter |
renderErrorContent |
| Methods inherited from class org.apache.cocoon.portal.coplet.adapter.impl.AbstractCopletAdapter |
destroy, getConfiguration, getConfiguration, init, login, logout, toSAX |
| Methods inherited from class org.apache.cocoon.portal.impl.AbstractComponent |
contextualize, initialize |
| Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled |
enableLogging, getLogger, setupLogger, setupLogger, setupLogger |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final String CONFIGURATION_ENABLE_CACHING
public static final String CONFIGURATION_CACHE_GLOBAL
public static final String CONFIGURATION_CACHE_GLOBAL_USE_ATTRIBUTES
public static final String CONFIGURATION_IGNORE_SIZING_EVENTS
public static final String CACHE
public static final String DO_NOT_CACHE
protected Cache cache
| Constructor Detail |
public CachingURICopletAdapter()
| Method Detail |
public void service(ServiceManager manager)
throws ServiceException
service in interface Serviceableservice in class URICopletAdapterServiceExceptionServiceable.service(org.apache.avalon.framework.service.ServiceManager)public void dispose()
dispose in interface Disposabledispose in class URICopletAdapterDisposable.dispose()
public void streamContent(CopletInstanceData coplet,
ContentHandler contentHandler)
throws SAXException
AbstractCopletAdapter
streamContent in class URICopletAdapterSAXExceptionAbstractCopletAdapter.streamContent(org.apache.cocoon.portal.coplet.CopletInstanceData, org.xml.sax.ContentHandler)
public void streamContent(CopletInstanceData coplet,
String uri,
ContentHandler contentHandler)
throws SAXException
streamContent in class URICopletAdapterSAXExceptionURICopletAdapter.streamContent(org.apache.cocoon.portal.coplet.CopletInstanceData, java.lang.String, org.xml.sax.ContentHandler)
public void inform(CopletInstanceEvent e,
PortalService service)
Receiverpublic void handleCopletInstanceEvent(CopletInstanceEvent event)
protected String getCacheKey(CopletInstanceData coplet,
String uri)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||