com.opensymphony.oscache.base
Class NeedsRefreshException
java.lang.Object
java.lang.Throwable
java.lang.Exception
com.opensymphony.oscache.base.NeedsRefreshException
- All Implemented Interfaces:
- Serializable
public final class NeedsRefreshException
- extends Exception
This exception is thrown when retrieving an item from cache and it is
expired.
Note that for fault tolerance purposes, it is possible to retrieve the
current cached object from the exception.
January, 2004 - The OSCache developers are aware of the fact that throwing
an exception for a perfect valid situation (cache miss) is design smell. This will
be removed in the near future, and other means of refreshing the cache will be
provided.
- Version:
- $Revision: 1.1 $
- Author:
- Francois Beauregard
- See Also:
- Serialized Form
Methods inherited from class java.lang.Throwable |
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString |
NeedsRefreshException
public NeedsRefreshException(Object cacheContent)
- Create a NeedsRefreshException
getCacheContent
public Object getCacheContent()
- Retrieve current object in the cache