K
- The key type of the LRUV
- The value type of the LRUpublic class LRU<K,V> extends LinkedHashMap<K,V>
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
Constructor and Description |
---|
LRU(int max)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected boolean |
removeEldestEntry(Map.Entry<K,V> entry) |
clear, containsValue, get
clone, containsKey, entrySet, isEmpty, keySet, put, putAll, remove, size, values
equals, hashCode, toString
public LRU(int max)
max
- the maximum number of entries to cacheprotected boolean removeEldestEntry(Map.Entry<K,V> entry)
removeEldestEntry
in class LinkedHashMap<K,V>
Copyright © 2003-2014 Internet Archive. All Rights Reserved.