/** Description of the Method */
public Serializable get( Serializable key, boolean container )
{
//IDiskElement ide = (IDiskElement)purgatory.get( key );
PurgatoryElement pe = ( PurgatoryElement ) purgatory.get( key );
//if ( ide != null ) {
if ( pe != null )
{
purgHits++;
if ( log.isDebugEnabled() )
{
if ( purgHits % 100 == 0 )
{
log.debug( "purgatory hits = " + purgHits );
}
}
pe.setSpoolable( false );
log.debug( "found in purgatory" );
if ( container )
{
purgatory.remove( key );
return pe.getCacheElement();
}
else
{
purgatory.remove( key );
return ( Serializable ) pe.getCacheElement().getVal();
}
}
try
{
return cache.get( key );