Package ghidra.generic.util.datastruct

# Class TreeValueSortedMap.ValueSortedTreeMapEntrySet

java.lang.Object
java.util.AbstractCollection<E>
java.util.AbstractSet<Map.Entry<K,V>>
ghidra.generic.util.datastruct.TreeValueSortedMap.ValueSortedTreeMapEntrySet

All Implemented Interfaces:
  `ValueSortedMap.ValueSortedMapEntryList<K,V>`, `Iterable<Map.Entry<K,V>>`, `Collection<Map.Entry<K,V>>`, `Deque<Map.Entry<K,V>>`, `List<Map.Entry<K,V>>`, `Queue<Map.Entry<K,V>>`, `Set<Map.Entry<K,V>>`

Enclosing class:
  TreeValueSortedMap<K,V>

protected class TreeValueSortedMap.ValueSortedTreeMapEntrySet extends AbstractSet<Map.Entry<K,V>> implements ValueSortedMap.ValueSortedMapEntryList<K,V>
A public view of the map as a set of entries In addition to `Set`, this view implements `List` and `Deque`, since an ordered set ought to behave like a list, and since this implementation is meant to be used as a dynamic-cost priority queue. Generally, all of the mutation methods are supported.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `add(int index, Map.Entry<K,V> element)`
  Inserts (by copy) the entry into the owning map, ignoring index
  `boolean`
  `add(Map.Entry<K,V> e)`
  Inserts (by copy) the entry into the owning map
  `boolean`
  `addAll(int index, Collection<? extends Map.Entry<K,V>> c)`
  Inserts (by copy) all entries in the collection, ignoring index
  `void`
  `addFirst(Map.Entry<K,V> e)`
  Inserts (by copy) the entry at its sorted position, not necessarily first
  `void`
  `addLast(Map.Entry<K,V> e)`
  Inserts (by copy) the entry at its sorted position, not necessarily last
  `void`
  `clear()`
  `boolean`
  `contains(Object o)`
  `Iterator<Map.Entry<K,V>>`
  `descendingIterator()`
  `Map.Entry<K,V>`
  `element()`
  `Map.Entry<K,V>`
  `get(int index)`
  `Map.Entry<K,V>`
  `getFirst()`
  `Map.Entry<K,V>`
  `getLast()`
  `int`
  `indexOf(Object o)`
  `boolean`
  `isEmpty()`
  `Iterator<Map.Entry<K,V>>`
  `iterator()`
  `int`
  `lastIndexOf(Object o)`
  `ListIterator<Map.Entry<K,V>>`
  `listIterator()`
  `ListIterator<Map.Entry<K,V>>`
  `listIterator(int index)`
  `boolean`
  `offer(Map.Entry<K,V> e)`
  `boolean`
  `offerFirst(Map.Entry<K,V> e)`
  Inserts (by copy) the entry at its sorted position, not necessarily first
  `boolean`
  `offerLast(Map.Entry<K,V> e)`
  Inserts (by copy) the entry at its sorted position, not necessarily last
  `Map.Entry<K,V>`
  `peek()`
  `Map.Entry<K,V>`
  `peekFirst()`
  `Map.Entry<K,V>`
  `peekLast()`
  `Map.Entry<K,V>`
  `poll()`
  `Map.Entry<K,V>`
  `pollFirst()`
  `Map.Entry<K,V>`
  `pollLast()`
  `Map.Entry<K,V>`
  `pop()`
  `void`
  `push(Map.Entry<K,V> e)`
  `Map.Entry<K,V>`
  `remove()`
  `Map.Entry<K,V>`
  `remove(int index)`
  `boolean`
  `remove(Object o)`
  `Map.Entry<K,V>`
  `removeFirst()`
  `boolean`
  `removeFirstOccurrence(Object o)`
  `Map.Entry<K,V>`
  `removeLast()`
  `boolean`
  `removeLastOccurrence(Object o)`
  `Map.Entry<K,V>`
  `set(int index, Map.Entry<K,V> element)`
  Modify the entry (key and value) at index Because the map is sorted by value, the index of the given entry may not remain the same after it is modified.
  `int`
  `size()`
  `List<Map.Entry<K,V>>`
  `subList(int fromIndex, int toIndex)`
  This operation is not supported

  ### Methods inherited from class java.util.AbstractSet

  `equals, hashCode, removeAll`

  ### Methods inherited from class java.util.AbstractCollection

  `addAll, containsAll, retainAll, toArray, toArray, toString`

  ### Methods inherited from class java.lang.Object

  `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

  ### Methods inherited from interface java.util.Collection

  `parallelStream, removeIf, stream, toArray`

  ### Methods inherited from interface java.util.Deque

  `addAll`

  ### Methods inherited from interface java.lang.Iterable

  `forEach`

  ### Methods inherited from interface java.util.List

  `addAll, containsAll, equals, hashCode, removeAll, replaceAll, retainAll, sort, toArray, toArray`

  ### Methods inherited from interface java.util.Set

  `addAll, containsAll, equals, hashCode, removeAll, retainAll, toArray, toArray`

  ### Methods inherited from interface ghidra.generic.util.datastruct.ValueSortedMap.ValueSortedMapEntryList

  `spliterator`

- ## Method Details

  - ### add

    public boolean add(Map.Entry<K,V> e)
    Inserts (by copy) the entry into the owning map
    Specified by:
      `add` in interface `Collection<Map.Entry<K,V>>`
    Specified by:
      `add` in interface `Deque<Map.Entry<K,V>>`
    Specified by:
      `add` in interface `List<Map.Entry<K,V>>`
    Specified by:
      `add` in interface `Queue<Map.Entry<K,V>>`
    Specified by:
      `add` in interface `Set<Map.Entry<K,V>>`
    Overrides:
      `add` in class `AbstractCollection<Map.Entry<K,V>>`

  - ### add

    public void add(int index, Map.Entry<K,V> element)
    Inserts (by copy) the entry into the owning map, ignoring index
    Specified by:
      `add` in interface `List<Map.Entry<K,V>>`
    Parameters:
      `index` - ignored since order is determined by the entry's value

  - ### addAll

    public boolean addAll(int index, Collection<? extends Map.Entry<K,V>> c)
    Inserts (by copy) all entries in the collection, ignoring index
    Specified by:
      `addAll` in interface `List<Map.Entry<K,V>>`
    Parameters:
      `index` - ignored since order is determined by the entries' values

  - ### addFirst

    public void addFirst(Map.Entry<K,V> e)
    Inserts (by copy) the entry at its sorted position, not necessarily first
    Specified by:
      `addFirst` in interface `Deque<Map.Entry<K,V>>`

  - ### addLast

    public void addLast(Map.Entry<K,V> e)
    Inserts (by copy) the entry at its sorted position, not necessarily last
    Specified by:
      `addLast` in interface `Deque<Map.Entry<K,V>>`

  - ### clear

    public void clear()
    Specified by:
      `clear` in interface `Collection<Map.Entry<K,V>>`
    Specified by:
      `clear` in interface `List<Map.Entry<K,V>>`
    Specified by:
      `clear` in interface `Set<Map.Entry<K,V>>`
    Overrides:
      `clear` in class `AbstractCollection<Map.Entry<K,V>>`

  - ### contains

    public boolean contains(Object o)
    Specified by:
      `contains` in interface `Collection<Map.Entry<K,V>>`
    Specified by:
      `contains` in interface `Deque<Map.Entry<K,V>>`
    Specified by:
      `contains` in interface `List<Map.Entry<K,V>>`
    Specified by:
      `contains` in interface `Set<Map.Entry<K,V>>`
    Overrides:
      `contains` in class `AbstractCollection<Map.Entry<K,V>>`

  - ### descendingIterator

    public Iterator<Map.Entry<K,V>> descendingIterator()
    Specified by:
      `descendingIterator` in interface `Deque<Map.Entry<K,V>>`

  - ### element

    public Map.Entry<K,V> element()
    Specified by:
      `element` in interface `Deque<Map.Entry<K,V>>`
    Specified by:
      `element` in interface `Queue<Map.Entry<K,V>>`

  - ### get

    public Map.Entry<K,V> get(int index)
    Specified by:
      `get` in interface `List<Map.Entry<K,V>>`

  - ### getFirst

    public Map.Entry<K,V> getFirst()
    Specified by:
      `getFirst` in interface `Deque<Map.Entry<K,V>>`

  - ### getLast

    public Map.Entry<K,V> getLast()
    Specified by:
      `getLast` in interface `Deque<Map.Entry<K,V>>`

  - ### indexOf

    public int indexOf(Object o)
    Specified by:
      `indexOf` in interface `List<Map.Entry<K,V>>`

  - ### isEmpty

    public boolean isEmpty()
    Specified by:
      `isEmpty` in interface `Collection<Map.Entry<K,V>>`
    Specified by:
      `isEmpty` in interface `List<Map.Entry<K,V>>`
    Specified by:
      `isEmpty` in interface `Set<Map.Entry<K,V>>`
    Overrides:
      `isEmpty` in class `AbstractCollection<Map.Entry<K,V>>`

  - ### iterator

    public Iterator<Map.Entry<K,V>> iterator()
    Specified by:
      `iterator` in interface `Collection<Map.Entry<K,V>>`
    Specified by:
      `iterator` in interface `Deque<Map.Entry<K,V>>`
    Specified by:
      `iterator` in interface `Iterable<Map.Entry<K,V>>`
    Specified by:
      `iterator` in interface `List<Map.Entry<K,V>>`
    Specified by:
      `iterator` in interface `Set<Map.Entry<K,V>>`
    Specified by:
      `iterator` in class `AbstractCollection<Map.Entry<K,V>>`

  - ### lastIndexOf

    public int lastIndexOf(Object o)
    Specified by:
      `lastIndexOf` in interface `List<Map.Entry<K,V>>`

  - ### listIterator

    public ListIterator<Map.Entry<K,V>> listIterator()
    Specified by:
      `listIterator` in interface `List<Map.Entry<K,V>>`

  - ### listIterator

    public ListIterator<Map.Entry<K,V>> listIterator(int index)
    Specified by:
      `listIterator` in interface `List<Map.Entry<K,V>>`

  - ### offer

    public boolean offer(Map.Entry<K,V> e)
    Specified by:
      `offer` in interface `Deque<Map.Entry<K,V>>`
    Specified by:
      `offer` in interface `Queue<Map.Entry<K,V>>`

  - ### offerFirst

    public boolean offerFirst(Map.Entry<K,V> e)
    Inserts (by copy) the entry at its sorted position, not necessarily first
    Specified by:
      `offerFirst` in interface `Deque<Map.Entry<K,V>>`

  - ### offerLast

    public boolean offerLast(Map.Entry<K,V> e)
    Inserts (by copy) the entry at its sorted position, not necessarily last
    Specified by:
      `offerLast` in interface `Deque<Map.Entry<K,V>>`

  - ### peek

    public Map.Entry<K,V> peek()
    Specified by:
      `peek` in interface `Deque<Map.Entry<K,V>>`
    Specified by:
      `peek` in interface `Queue<Map.Entry<K,V>>`

  - ### peekFirst

    public Map.Entry<K,V> peekFirst()
    Specified by:
      `peekFirst` in interface `Deque<Map.Entry<K,V>>`

  - ### peekLast

    public Map.Entry<K,V> peekLast()
    Specified by:
      `peekLast` in interface `Deque<Map.Entry<K,V>>`

  - ### poll

    public Map.Entry<K,V> poll()
    Specified by:
      `poll` in interface `Deque<Map.Entry<K,V>>`
    Specified by:
      `poll` in interface `Queue<Map.Entry<K,V>>`

  - ### pollFirst

    public Map.Entry<K,V> pollFirst()
    Specified by:
      `pollFirst` in interface `Deque<Map.Entry<K,V>>`

  - ### pollLast

    public Map.Entry<K,V> pollLast()
    Specified by:
      `pollLast` in interface `Deque<Map.Entry<K,V>>`

  - ### pop

    public Map.Entry<K,V> pop()
    Specified by:
      `pop` in interface `Deque<Map.Entry<K,V>>`

  - ### push

    public void push(Map.Entry<K,V> e)
    Specified by:
      `push` in interface `Deque<Map.Entry<K,V>>`

  - ### remove

    public Map.Entry<K,V> remove()
    Specified by:
      `remove` in interface `Deque<Map.Entry<K,V>>`
    Specified by:
      `remove` in interface `Queue<Map.Entry<K,V>>`

  - ### remove

    public Map.Entry<K,V> remove(int index)
    Specified by:
      `remove` in interface `List<Map.Entry<K,V>>`

  - ### remove

    public boolean remove(Object o)
    Specified by:
      `remove` in interface `Collection<Map.Entry<K,V>>`
    Specified by:
      `remove` in interface `Deque<Map.Entry<K,V>>`
    Specified by:
      `remove` in interface `List<Map.Entry<K,V>>`
    Specified by:
      `remove` in interface `Set<Map.Entry<K,V>>`
    Overrides:
      `remove` in class `AbstractCollection<Map.Entry<K,V>>`

  - ### removeFirst

    public Map.Entry<K,V> removeFirst()
    Specified by:
      `removeFirst` in interface `Deque<Map.Entry<K,V>>`

  - ### removeFirstOccurrence

    public boolean removeFirstOccurrence(Object o)
    Specified by:
      `removeFirstOccurrence` in interface `Deque<Map.Entry<K,V>>`

  - ### removeLast

    public Map.Entry<K,V> removeLast()
    Specified by:
      `removeLast` in interface `Deque<Map.Entry<K,V>>`

  - ### removeLastOccurrence

    public boolean removeLastOccurrence(Object o)
    Specified by:
      `removeLastOccurrence` in interface `Deque<Map.Entry<K,V>>`

  - ### set

    public Map.Entry<K,V> set(int index, Map.Entry<K,V> element)
    Modify the entry (key and value) at index Because the map is sorted by value, the index of the given entry may not remain the same after it is modified. In fact, this is equivalent to removing the entry at the given index, and then inserting the given entry at its sorted position.
    Specified by:
      `set` in interface `List<Map.Entry<K,V>>`

  - ### size

    public int size()
    Specified by:
      `size` in interface `Collection<Map.Entry<K,V>>`
    Specified by:
      `size` in interface `Deque<Map.Entry<K,V>>`
    Specified by:
      `size` in interface `List<Map.Entry<K,V>>`
    Specified by:
      `size` in interface `Set<Map.Entry<K,V>>`
    Specified by:
      `size` in class `AbstractCollection<Map.Entry<K,V>>`

  - ### subList

    public List<Map.Entry<K,V>> subList(int fromIndex, int toIndex)
    This operation is not supported
    Specified by:
      `subList` in interface `List<Map.Entry<K,V>>`