K
- Key typeV
- Value typepublic class WeakIdentityHashMap<K,V> extends Object implements Map<K,V>
WeakHashMap
and IdentityHashMap
Modifier and Type | Class and Description |
---|---|
protected static class |
WeakIdentityHashMap.Entry<K,V> |
protected static class |
WeakIdentityHashMap.KeyRef<K> |
Modifier and Type | Field and Description |
---|---|
protected Map<WeakIdentityHashMap.KeyRef<K>,V> |
map |
protected ReferenceQueue<K> |
refQueue |
Constructor and Description |
---|
WeakIdentityHashMap() |
Modifier and Type | Method and Description |
---|---|
void |
clear() |
protected void |
clearReferences() |
boolean |
containsKey(Object key) |
boolean |
containsValue(Object value) |
Set<Map.Entry<K,V>> |
entrySet() |
V |
get(Object key) |
boolean |
isEmpty() |
Set<K> |
keySet() |
V |
put(K key,
V value) |
void |
putAll(Map<? extends K,? extends V> m) |
V |
remove(Object key) |
int |
size() |
Collection<V> |
values() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
compute, computeIfAbsent, computeIfPresent, equals, forEach, getOrDefault, hashCode, merge, putIfAbsent, remove, replace, replace, replaceAll
protected final Map<WeakIdentityHashMap.KeyRef<K>,V> map
protected final ReferenceQueue<K> refQueue
protected void clearReferences()
public boolean containsKey(Object key)
containsKey
in interface Map<K,V>
public boolean containsValue(Object value)
containsValue
in interface Map<K,V>
Copyright © 2020. All rights reserved.