Package ghidra.util.datastruct
Class AbstractWeakValueNavigableMap<K,V>
- java.lang.Object
-
- ghidra.util.datastruct.AbstractWeakValueMap<K,V>
-
- ghidra.util.datastruct.AbstractWeakValueNavigableMap<K,V>
-
- Type Parameters:
K
- the type of keysV
- the type of values
- All Implemented Interfaces:
java.util.Map<K,V>
,java.util.NavigableMap<K,V>
,java.util.SortedMap<K,V>
- Direct Known Subclasses:
AbstractWeakValueNavigableMap.NavigableView
,WeakValueTreeMap
public abstract class AbstractWeakValueNavigableMap<K,V> extends AbstractWeakValueMap<K,V> implements java.util.NavigableMap<K,V>
Class to provide a navigable, e.g., tree-, map with weak values
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
AbstractWeakValueNavigableMap.NavigableView<K,V>
A view of this same map that limits or changes the order of the keys-
Nested classes/interfaces inherited from class ghidra.util.datastruct.AbstractWeakValueMap
AbstractWeakValueMap.GeneratedEntry, AbstractWeakValueMap.WeakValueRef<K,V>
-
-
Field Summary
-
Fields inherited from class ghidra.util.datastruct.AbstractWeakValueMap
refQueue
-
-
Constructor Summary
Constructors Constructor Description AbstractWeakValueNavigableMap()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description java.util.Map.Entry<K,V>
ceilingEntry(K key)
K
ceilingKey(K key)
java.util.Comparator<? super K>
comparator()
java.util.NavigableSet<K>
descendingKeySet()
java.util.NavigableMap<K,V>
descendingMap()
java.util.Map.Entry<K,V>
firstEntry()
K
firstKey()
java.util.Map.Entry<K,V>
floorEntry(K key)
K
floorKey(K key)
protected AbstractWeakValueMap.GeneratedEntry
generateEntry(java.util.Map.Entry<K,AbstractWeakValueMap.WeakValueRef<K,V>> ent)
Construct a generated (wrapper) entry, for the entry-retrieval methods.protected abstract java.util.NavigableMap<K,AbstractWeakValueMap.WeakValueRef<K,V>>
getRefMap()
Returns the backing mapjava.util.SortedMap<K,V>
headMap(K toKey)
java.util.NavigableMap<K,V>
headMap(K toKey, boolean inclusive)
java.util.Map.Entry<K,V>
higherEntry(K key)
K
higherKey(K key)
java.util.Map.Entry<K,V>
lastEntry()
K
lastKey()
java.util.Map.Entry<K,V>
lowerEntry(K key)
K
lowerKey(K key)
java.util.NavigableSet<K>
navigableKeySet()
java.util.Map.Entry<K,V>
pollFirstEntry()
java.util.Map.Entry<K,V>
pollLastEntry()
java.util.NavigableMap<K,V>
subMap(K fromKey, boolean fromInclusive, K toKey, boolean toInclusive)
java.util.SortedMap<K,V>
subMap(K fromKey, K toKey)
java.util.SortedMap<K,V>
tailMap(K fromKey)
java.util.NavigableMap<K,V>
tailMap(K fromKey, boolean inclusive)
-
Methods inherited from class ghidra.util.datastruct.AbstractWeakValueMap
clear, containsKey, containsValue, entrySet, get, isEmpty, keySet, processQueue, put, putAll, remove, size, values
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
-
-
Method Detail
-
getRefMap
protected abstract java.util.NavigableMap<K,AbstractWeakValueMap.WeakValueRef<K,V>> getRefMap()
Description copied from class:AbstractWeakValueMap
Returns the backing map- Specified by:
getRefMap
in classAbstractWeakValueMap<K,V>
- Returns:
- the map
-
comparator
public java.util.Comparator<? super K> comparator()
-
generateEntry
protected AbstractWeakValueMap.GeneratedEntry generateEntry(java.util.Map.Entry<K,AbstractWeakValueMap.WeakValueRef<K,V>> ent)
Construct a generated (wrapper) entry, for the entry-retrieval methods.This handles the null case in one place.
- Parameters:
ent
- the entry to wrap, possibly null- Returns:
- the generated entry, or null
-
navigableKeySet
public java.util.NavigableSet<K> navigableKeySet()
-
descendingKeySet
public java.util.NavigableSet<K> descendingKeySet()
-
subMap
public java.util.NavigableMap<K,V> subMap(K fromKey, boolean fromInclusive, K toKey, boolean toInclusive)
-
-