K - 键V - 值public class WeakCache<K,V> extends TimedCache<K,V>
lockcacheMap, capacity, existCustomTimeout, hitCount, keyLockMap, listener, missCount, timeout| Constructor and Description |
|---|
WeakCache(long timeout)
构造
|
| Modifier and Type | Method and Description |
|---|---|
WeakCache<K,V> |
setListener(CacheListener<K,V> listener)
设置监听
|
cancelPruneSchedule, pruneCache, schedulePrunecacheObjIterator, clear, containsKey, get, prune, put, remove, toStringcacheObjIter, capacity, get, get, getHitCount, getMissCount, getWithoutLock, isEmpty, isFull, isPruneExpiredActive, iterator, keySet, onRemove, put, putWithoutLock, removeWithoutLock, size, timeoutclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitforEach, spliteratorpublic WeakCache(long timeout)
timeout - 超时时常,单位毫秒,-1或0表示无限制public WeakCache<K,V> setListener(CacheListener<K,V> listener)
AbstractCachesetListener in interface Cache<K,V>setListener in class AbstractCache<K,V>listener - 监听Copyright © 2025. All rights reserved.