K - The type of the keys.V - The type of the values.public class BoundedConcurrentHashMap<K,V>
extends java.util.concurrent.ConcurrentHashMap<K,V>
| Modifier and Type | Class and Description |
|---|---|
static class |
BoundedConcurrentHashMap.BoundedCacheBehaviour |
java.util.concurrent.ConcurrentHashMap.KeySetView<K,V>| Constructor and Description |
|---|
BoundedConcurrentHashMap(BoundedConcurrentHashMap.BoundedCacheBehaviour boundedCacheBehaviour,
int maxCacheSize)
Initialize a bounded concurrent hash map.
|
| Modifier and Type | Method and Description |
|---|---|
V |
put(K key,
V value)
Works like the overriden method, except that
null is returned, if the given element could not be added
due to map limitations. |
V |
putIfAbsent(K key,
V value)
Works like the overriden method, except that
null is returned, if the given element could not be added
due to map limitations. |
clear, compute, computeIfAbsent, computeIfPresent, contains, containsKey, containsValue, elements, entrySet, equals, forEach, forEach, forEach, forEachEntry, forEachEntry, forEachKey, forEachKey, forEachValue, forEachValue, get, getOrDefault, hashCode, isEmpty, keys, keySet, keySet, mappingCount, merge, newKeySet, newKeySet, putAll, reduce, reduceEntries, reduceEntries, reduceEntriesToDouble, reduceEntriesToInt, reduceEntriesToLong, reduceKeys, reduceKeys, reduceKeysToDouble, reduceKeysToInt, reduceKeysToLong, reduceToDouble, reduceToInt, reduceToLong, reduceValues, reduceValues, reduceValuesToDouble, reduceValuesToInt, reduceValuesToLong, remove, remove, replace, replace, replaceAll, search, searchEntries, searchKeys, searchValues, size, toString, valuespublic BoundedConcurrentHashMap(BoundedConcurrentHashMap.BoundedCacheBehaviour boundedCacheBehaviour, int maxCacheSize)
boundedCacheBehaviour - set the cache behaviormaxCacheSize - define limit of the cachepublic V put(K key, V value)
null is returned, if the given element could not be added
due to map limitations.put in interface java.util.Map<K,V>put in class java.util.concurrent.ConcurrentHashMap<K,V>key - key-valuevalue - the associated valuepublic V putIfAbsent(K key, V value)
null is returned, if the given element could not be added
due to map limitations.putIfAbsent in interface java.util.concurrent.ConcurrentMap<K,V>putIfAbsent in interface java.util.Map<K,V>putIfAbsent in class java.util.concurrent.ConcurrentHashMap<K,V>key - key-valuevalue - the associated valueCopyright 2021 Kieker Project, http://kieker-monitoring.net