Package ghidra.generic.util.datastruct
Class TreeValueSortedMap.ValueSortedTreeMapValues
java.lang.Object
java.util.AbstractCollection<V>
ghidra.generic.util.datastruct.TreeValueSortedMap.ValueSortedTreeMapValues
- All Implemented Interfaces:
SortedList<V>,ValueSortedMap.LesserList<V>,Iterable<V>,Collection<V>
- Enclosing class:
TreeValueSortedMap<K,V>
protected class TreeValueSortedMap.ValueSortedTreeMapValues
extends AbstractCollection<V>
implements SortedList<V>
A public view of the map as a list of values
This view implements
SortedList and Deque, since an ordered collection ought
to behave like a list, and since this implementation is meant to be used as a dynamic-cost
priority queue.
Generally, only the removal mutation methods are supported, all others are not supported.-
Method Summary
Modifier and TypeMethodDescriptionintceilingIndex(V element) Returns the least index in this list whose element is greater than or equal to the specified elementvoidclear()booleanintfloorIndex(V element) Returns the greatest index in this list whose element is less than or equal to the specified elementget(int index) Get the element at the given indexinthigherIndex(V element) Returns the least index in this list whose element is strictly greater the specified elementintGet the index of a given elementbooleanisEmpty()iterator()listIterator(int index) intlowerIndex(V element) Returns the greatest index in this list whose element is strictly less than the specified elementpoll()Get and remove the first elementbooleanintsize()toList()Copy this to a new listMethods inherited from class java.util.AbstractCollection
add, addAll, containsAll, removeAll, retainAll, toArray, toArray, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.util.Collection
equals, hashCode, parallelStream, removeIf, spliterator, stream, toArrayMethods inherited from interface ghidra.generic.util.datastruct.ValueSortedMap.LesserList
removeAll
-
Method Details
-
toList
Description copied from interface:ValueSortedMap.LesserListCopy this to a new list- Specified by:
toListin interfaceValueSortedMap.LesserList<V>- Returns:
- the list
-
clear
public void clear()- Specified by:
clearin interfaceCollection<V>- Overrides:
clearin classAbstractCollection<V>
-
contains
- Specified by:
containsin interfaceCollection<V>- Specified by:
containsin interfaceValueSortedMap.LesserList<V>- Overrides:
containsin classAbstractCollection<V>
-
get
Description copied from interface:ValueSortedMap.LesserListGet the element at the given index- Specified by:
getin interfaceValueSortedMap.LesserList<V>- Parameters:
index- the index- Returns:
- the element
-
indexOf
Description copied from interface:ValueSortedMap.LesserListGet the index of a given elementReturns the index of the element, or -1 if not found
- Specified by:
indexOfin interfaceValueSortedMap.LesserList<V>- Parameters:
o- the object- Returns:
- the index or -1
-
lowerIndex
Description copied from interface:SortedListReturns the greatest index in this list whose element is strictly less than the specified element- Specified by:
lowerIndexin interfaceSortedList<V>- Parameters:
element- the element to search for- Returns:
- the index of the found element, or -1
-
floorIndex
Description copied from interface:SortedListReturns the greatest index in this list whose element is less than or equal to the specified elementIf multiples of the specified element exist, this returns the least index of that element.
- Specified by:
floorIndexin interfaceSortedList<V>- Parameters:
element- the element to search for- Returns:
- the index of the found element, or -1
-
ceilingIndex
Description copied from interface:SortedListReturns the least index in this list whose element is greater than or equal to the specified elementIf multiples of the specified element exist, this returns the greatest index of that element.
- Specified by:
ceilingIndexin interfaceSortedList<V>- Parameters:
element- the element to search for- Returns:
- the index of the found element, or -1
-
higherIndex
Description copied from interface:SortedListReturns the least index in this list whose element is strictly greater the specified element- Specified by:
higherIndexin interfaceSortedList<V>- Parameters:
element- the element to search for- Returns:
- the index of the found element, or -1
-
isEmpty
public boolean isEmpty()- Specified by:
isEmptyin interfaceCollection<V>- Specified by:
isEmptyin interfaceValueSortedMap.LesserList<V>- Overrides:
isEmptyin classAbstractCollection<V>
-
listIterator
- Specified by:
listIteratorin interfaceValueSortedMap.LesserList<V>
-
iterator
- Specified by:
iteratorin interfaceCollection<V>- Specified by:
iteratorin interfaceIterable<V>- Specified by:
iteratorin classAbstractCollection<V>
-
poll
Description copied from interface:ValueSortedMap.LesserListGet and remove the first element- Specified by:
pollin interfaceValueSortedMap.LesserList<V>- Returns:
- the first element, or null if empty
-
remove
- Specified by:
removein interfaceCollection<V>- Specified by:
removein interfaceValueSortedMap.LesserList<V>- Overrides:
removein classAbstractCollection<V>
-
size
public int size()- Specified by:
sizein interfaceCollection<V>- Specified by:
sizein interfaceValueSortedMap.LesserList<V>- Specified by:
sizein classAbstractCollection<V>
-