FileDocCategorySizeDatePackage
PassivatedSessionCache.javaAPI DocGlassfish v2 API3139Fri May 04 22:33:00 BST 2007com.sun.ejb.containers.util.cache

PassivatedSessionCache

public class PassivatedSessionCache extends LruCache

Fields Summary
Constructors Summary
public PassivatedSessionCache()
default constructor

        super();
    
public PassivatedSessionCache(long timeout)
constructor with specified timeout

        super(timeout);
    
Methods Summary
protected booleanisThresholdReached()

        return false;
    
protected CacheItemitemAdded(CacheItem item)
this item is just added to the cache

param
item CacheItem that was created
return
a overflow item; may be null Cache bucket is already synchronized by the caller

        CacheItem overflow = null;
        LruCacheItem lc = (LruCacheItem) item;

        // set the timestamp
        lc.lastAccessed = ((Long) item.value).longValue();

        // update the LRU
        synchronized (this) {
            if (head != null) {
                head.lPrev = lc;
                lc.lNext = head;
            }
            else {
                tail = lc;
            }
            head = lc;

            listSize++;

        }

        return overflow;