|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.9.0) E52944-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.javatools.util.Maps.CacheStrategy<K,V>
oracle.javatools.util.Maps.BoundedLruCacheStrategy<K,V>
public static class Maps.BoundedLruCacheStrategy<K,V>
A bounded size LRU (least recently used) cache strategy.
Maps.CacheMap
, Maps.CacheStrategy
, Serialized FormField Summary |
---|
Fields inherited from class oracle.javatools.util.Maps.CacheStrategy |
---|
CANONICAL, DEFAULT_INITIAL_CAPACITY, DEFAULT_LOAD_FACTOR, HARD, NONCANONICAL, NOT_CANONICAL, SOFT, STRONG, WEAK |
Constructor Summary | |
---|---|
Maps.BoundedLruCacheStrategy(int bound) Constructs a bounded LRU (least recently used), canonical, cache strategy of strongly-referenced values. |
|
Maps.BoundedLruCacheStrategy(int bound, int initialCapacity, float loadFactor, Maps.CacheMap.Canonicity canonicity, Maps.CacheMap.Strength strength) Constructs a bounded LRU (least recently used) cache strategy. |
|
Maps.BoundedLruCacheStrategy(int bound, Maps.CacheMap.Canonicity canonicity, Maps.CacheMap.Strength strength) Constructs a bounded LRU (least recently used) cache strategy. |
|
Maps.BoundedLruCacheStrategy(int bound, Maps.CacheMap.Strength strength) Constructs a bounded LRU (least recently used), canonical cache strategy. |
Method Summary | |
---|---|
protected void |
entryAdded(Maps.CacheMap<K,V> map, Maps.LinkedEntry<K,V> entry) Invoked when a new entry is added to this map, when entries are added by Maps.AbstractHashMap.put(K, V) . |
Methods inherited from class oracle.javatools.util.Maps.CacheStrategy |
---|
createDefaultEntry, createEntry, createEvictedEntry, createSoftEntry, createWeakEntry, entryAccessed, entryChanged, entryEvicted, entryPurged, entryRemoved, getCanonicity, getDefaultStrength, getInitialCapacity, getLoadFactor, mapChanged, mapConstructed |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Maps.BoundedLruCacheStrategy(int bound)
maximumSize+1
and 1.0f
, respectively, which ensures that the map will not have to resize before reaching its maximum size.
bound
- The maximum number of entries allowed in the cache.public Maps.BoundedLruCacheStrategy(int bound, Maps.CacheMap.Strength strength)
maximumSize+1
and 1.0f
, respectively, which ensures that the map will not have to resize before reaching its maximum size.
bound
- The maximum number of entries allowed in the cache.strength
- The strength of value references.public Maps.BoundedLruCacheStrategy(int bound, Maps.CacheMap.Canonicity canonicity, Maps.CacheMap.Strength strength)
maximumSize+1
and 1.0f
, respectively, which ensures that the map will not have to resize before reaching its maximum size.
bound
- The maximum number of entries allowed in the cache.canonicity
- The mapping type, canonical or not.strength
- The strength of value references.public Maps.BoundedLruCacheStrategy(int bound, int initialCapacity, float loadFactor, Maps.CacheMap.Canonicity canonicity, Maps.CacheMap.Strength strength)
bound
- The maximum number of entries allowed in the cache.initialCapacity
- The initial capacity (see Maps.CacheStrategy.DEFAULT_INITIAL_CAPACITY
).loadFactor
- The load factor (see Maps.CacheStrategy.DEFAULT_LOAD_FACTOR
).canonicity
- The mapping type, canonical or not.strength
- The strength of value references.Method Detail |
---|
protected void entryAdded(Maps.CacheMap<K,V> map, Maps.LinkedEntry<K,V> entry)
Maps.AbstractHashMap.put(K, V)
.
The Maps.CacheStrategy
implementation does nothing.
The Maps.BoundedLruCacheStrategy
implementation evicts the eldest entry in the map if the size of the map after the add exceeds the maximum size.
entryAdded
in class Maps.CacheStrategy<K,V>
|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.9.0) E52944-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |