public class BufferCache<K> extends OverflowingLRUCache<K,IBuffer>
IBuffers.LRUCache.LRUCacheEntry<K,V>, LRUCache.StatsloadFactor, overflow, timestampsOncurrentSpace, DEFAULT_SPACELIMIT, entryQueue, entryQueueTail, entryTable, spaceLimit, timestampCounter| Constructor and Description |
|---|
BufferCache(int size)
Constructs a new buffer cache of the given size.
|
BufferCache(int size,
int overflow)
Constructs a new buffer cache of the given size.
|
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
close(LRUCache.LRUCacheEntry<K,IBuffer> entry)
Returns true if the element is successfully closed and
removed from the cache, otherwise false.
|
protected LRUCache<K,IBuffer> |
newInstance(int size,
int newOverflow)
Returns a new instance of the reciever.
|
clone, elements, fillingRatio, getEntryTable, getLoadFactor, getOverflow, makeSpace, printStats, privateRemoveEntry, privateRemoveEntry, put, remove, setLoadFactor, setSpaceLimit, shrink, toString, updateTimestampflush, flush, get, getCurrentSpace, getKey, getNewestTimestampCounter, getOldestElement, getOldestTimestampCounter, getSpaceLimit, keys, keysAndValues, newInstance, peek, privateAdd, privateAddEntry, removeKey, spaceFor, toStringContents, toStringFillingRationpublic BufferCache(int size)
public BufferCache(int size,
int overflow)
protected boolean close(LRUCache.LRUCacheEntry<K,IBuffer> entry)
OverflowingLRUCacheNOTE: this triggers an external remove from the cache by closing the object.
close in class OverflowingLRUCache<K,IBuffer>protected LRUCache<K,IBuffer> newInstance(int size, int newOverflow)
OverflowingLRUCachenewInstance in class OverflowingLRUCache<K,IBuffer>