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>
,java.lang.Iterable<V>
,java.util.Collection<V>
,java.util.Deque<V>
,java.util.List<V>
,java.util.Queue<V>
- Enclosing class:
- TreeValueSortedMap<K,V>
protected class TreeValueSortedMap.ValueSortedTreeMapValues extends java.util.AbstractCollection<V> implements SortedList<V>, java.util.Deque<V>
A public view of the map as a list of values This view implementsSortedList
andDeque
, 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
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(int index, V element)
boolean
add(V e)
boolean
addAll(int index, java.util.Collection<? extends V> c)
boolean
addAll(java.util.Collection<? extends V> c)
void
addFirst(V e)
void
addLast(V e)
int
ceilingIndex(V element)
Returns the least index in this list whose element is greater than or equal to the specified elementvoid
clear()
boolean
contains(java.lang.Object o)
java.util.Iterator<V>
descendingIterator()
V
element()
int
floorIndex(V element)
Returns the greatest index in this list whose element is less than or equal to the specified elementV
get(int index)
V
getFirst()
V
getLast()
int
higherIndex(V element)
Returns the least index in this list whose element is strictly greater the specified elementint
indexOf(java.lang.Object o)
boolean
isEmpty()
java.util.Iterator<V>
iterator()
int
lastIndexOf(java.lang.Object o)
java.util.ListIterator<V>
listIterator()
java.util.ListIterator<V>
listIterator(int index)
int
lowerIndex(V element)
Returns the greatest index in this list whose element is strictly less than the specified elementboolean
offer(V e)
boolean
offerFirst(V e)
boolean
offerLast(V e)
V
peek()
V
peekFirst()
V
peekLast()
V
poll()
V
pollFirst()
V
pollLast()
V
pop()
void
push(V e)
V
remove()
V
remove(int index)
boolean
remove(java.lang.Object o)
V
removeFirst()
boolean
removeFirstOccurrence(java.lang.Object o)
V
removeLast()
boolean
removeLastOccurrence(java.lang.Object o)
V
set(int index, V element)
int
size()
java.util.List<V>
subList(int fromIndex, int toIndex)
This operation is not supported-
Methods inherited from class java.util.AbstractCollection
containsAll, removeAll, retainAll, toArray, toArray, toString
-
-
-
-
Method Detail
-
add
public boolean add(V e)
-
addAll
public boolean addAll(java.util.Collection<? extends V> c)
-
addAll
public boolean addAll(int index, java.util.Collection<? extends V> c)
- Specified by:
addAll
in interfacejava.util.List<V>
-
clear
public void clear()
-
contains
public boolean contains(java.lang.Object o)
-
descendingIterator
public java.util.Iterator<V> descendingIterator()
- Specified by:
descendingIterator
in interfacejava.util.Deque<V>
-
element
public V element()
-
indexOf
public int indexOf(java.lang.Object o)
- Specified by:
indexOf
in interfacejava.util.List<V>
-
lowerIndex
public int lowerIndex(V element)
Description copied from interface:SortedList
Returns the greatest index in this list whose element is strictly less than the specified element- Specified by:
lowerIndex
in interfaceSortedList<V>
- Parameters:
element
- the element to search for- Returns:
- the index of the found element, or -1
-
floorIndex
public int floorIndex(V element)
Description copied from interface:SortedList
Returns 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:
floorIndex
in interfaceSortedList<V>
- Parameters:
element
- the element to search for- Returns:
- the index of the found element, or -1
-
ceilingIndex
public int ceilingIndex(V element)
Description copied from interface:SortedList
Returns 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:
ceilingIndex
in interfaceSortedList<V>
- Parameters:
element
- the element to search for- Returns:
- the index of the found element, or -1
-
higherIndex
public int higherIndex(V element)
Description copied from interface:SortedList
Returns the least index in this list whose element is strictly greater the specified element- Specified by:
higherIndex
in interfaceSortedList<V>
- Parameters:
element
- the element to search for- Returns:
- the index of the found element, or -1
-
isEmpty
public boolean isEmpty()
-
iterator
public java.util.Iterator<V> iterator()
-
lastIndexOf
public int lastIndexOf(java.lang.Object o)
- Specified by:
lastIndexOf
in interfacejava.util.List<V>
-
listIterator
public java.util.ListIterator<V> listIterator()
- Specified by:
listIterator
in interfacejava.util.List<V>
-
listIterator
public java.util.ListIterator<V> listIterator(int index)
- Specified by:
listIterator
in interfacejava.util.List<V>
-
offer
public boolean offer(V e)
-
peek
public V peek()
-
poll
public V poll()
-
remove
public V remove()
-
remove
public boolean remove(java.lang.Object o)
-
removeFirstOccurrence
public boolean removeFirstOccurrence(java.lang.Object o)
- Specified by:
removeFirstOccurrence
in interfacejava.util.Deque<V>
-
removeLastOccurrence
public boolean removeLastOccurrence(java.lang.Object o)
- Specified by:
removeLastOccurrence
in interfacejava.util.Deque<V>
-
size
public int size()
-
-