public class FIFOEJBObjectCache extends com.sun.ejb.containers.util.cache.LruEJBCache implements EJBObjectCache
| Modifier and Type | Class and Description |
|---|---|
protected static class |
FIFOEJBObjectCache.EJBObjectCacheItem |
| Modifier and Type | Field and Description |
|---|---|
protected static boolean |
_printRefCount |
protected EJBObjectCacheListener |
listener |
protected int |
maxCacheSize |
protected String |
name |
protected Object |
refCountLock |
protected int |
totalRefCount |
| Constructor and Description |
|---|
FIFOEJBObjectCache(String name)
default constructor
|
FIFOEJBObjectCache(String name,
long timeout)
constructor with specified timeout
|
| Modifier and Type | Method and Description |
|---|---|
protected com.sun.appserv.util.cache.BaseCache.CacheItem |
createItem(int hashCode,
Object key,
Object value,
int size) |
protected void |
decrementReferenceCount() |
protected void |
decrementReferenceCount(int count) |
Object |
get(Object key) |
Object |
get(Object key,
boolean incrementRefCount) |
Map |
getStats() |
protected void |
incrementReferenceCount() |
void |
init(int maxEntries,
int numberOfVictimsToSelect,
long timeout,
float loadFactor,
Properties props) |
protected Object |
internalGet(int hashCode,
Object key,
boolean incrementRefCount) |
protected Object |
internalPut(int hashCode,
Object key,
Object value,
int size,
boolean incrementRefCount) |
protected Object |
internalRemove(Object key,
boolean decrementRefCount) |
protected boolean |
isThresholdReached() |
protected void |
itemAccessed(com.sun.appserv.util.cache.BaseCache.CacheItem item) |
protected void |
itemRemoved(com.sun.appserv.util.cache.BaseCache.CacheItem item) |
static void |
main(String[] args) |
void |
print() |
Object |
put(Object key,
Object value) |
Object |
put(Object key,
Object value,
boolean incrementRefCount) |
Object |
remove(Object key) |
Object |
remove(Object key,
boolean decrementRefCount) |
void |
setEJBObjectCacheListener(EJBObjectCacheListener listener) |
void |
trimExpiredEntries(int maxCount) |
itemAdded, setCacheName, trimLrugetStatByName, init, itemRefreshed, setTimeout_put, _remove, _removeItem, add, add, addCacheListener, clear, clearStats, contains, decrementEntryCount, destroy, elements, eq, get, getAll, getEntryCount, getIndex, getIndex, handleOverflow, hash, incrementAddCount, incrementEntryCount, incrementHitCount, incrementMissCount, incrementOverflowCount, incrementRefreshCount, incrementRemovalCount, init, init, isEmpty, keys, loadValue, notifyRefresh, put, remove, remove, removeAll, trimItem, values, waitRefreshprotected int maxCacheSize
protected String name
protected EJBObjectCacheListener listener
protected Object refCountLock
protected int totalRefCount
protected static final boolean _printRefCount
public FIFOEJBObjectCache(String name)
public FIFOEJBObjectCache(String name, long timeout)
public void init(int maxEntries,
int numberOfVictimsToSelect,
long timeout,
float loadFactor,
Properties props)
init in interface EJBObjectCachepublic void setEJBObjectCacheListener(EJBObjectCacheListener listener)
setEJBObjectCacheListener in interface EJBObjectCachepublic Object get(Object key)
get in interface com.sun.appserv.util.cache.Cacheget in class com.sun.appserv.util.cache.BaseCachepublic Object get(Object key, boolean incrementRefCount)
get in interface EJBObjectCachepublic Object put(Object key, Object value)
put in interface com.sun.appserv.util.cache.Cacheput in class com.sun.appserv.util.cache.BaseCachepublic Object put(Object key, Object value, boolean incrementRefCount)
put in interface EJBObjectCachepublic Object remove(Object key)
remove in interface com.sun.appserv.util.cache.Cacheremove in class com.sun.appserv.util.cache.BaseCachepublic Object remove(Object key, boolean decrementRefCount)
remove in interface EJBObjectCacheprotected boolean isThresholdReached()
isThresholdReached in class com.sun.appserv.util.cache.BaseCacheprotected void itemAccessed(com.sun.appserv.util.cache.BaseCache.CacheItem item)
itemAccessed in class com.sun.appserv.util.cache.LruCacheprotected void itemRemoved(com.sun.appserv.util.cache.BaseCache.CacheItem item)
itemRemoved in class com.sun.appserv.util.cache.LruCacheprotected Object internalPut(int hashCode, Object key, Object value, int size, boolean incrementRefCount)
public void print()
protected com.sun.appserv.util.cache.BaseCache.CacheItem createItem(int hashCode,
Object key,
Object value,
int size)
createItem in class com.sun.appserv.util.cache.LruCachepublic Map getStats()
getStats in interface com.sun.appserv.util.cache.CachegetStats in class com.sun.appserv.util.cache.LruCachepublic void trimExpiredEntries(int maxCount)
trimExpiredEntries in interface com.sun.appserv.util.cache.CachetrimExpiredEntries in class com.sun.appserv.util.cache.LruCacheprotected void incrementReferenceCount()
protected void decrementReferenceCount()
protected void decrementReferenceCount(int count)
Copyright © 2017–2020 Eclipse Foundation. All rights reserved.