Package org.agrona.collections
Class Int2ObjectHashMap.EntrySet
- All Implemented Interfaces:
Iterable<Map.Entry<Integer,
,V>> Collection<Map.Entry<Integer,
,V>> Set<Map.Entry<Integer,
V>>
- Enclosing class:
Int2ObjectHashMap<V>
Set of entries which supports access via an optionally cached iterator to avoid allocation.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
boolean
iterator()
boolean
removeIfInt
(IntObjPredicate<V> filter) Removes all the elements of this collection that satisfy the given predicate.int
size()
Object[]
toArray()
<T> T[]
toArray
(T[] a) Methods inherited from class java.util.AbstractSet
equals, hashCode, removeAll
Methods inherited from class java.util.AbstractCollection
add, addAll, containsAll, isEmpty, remove, retainAll, 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.Set
add, addAll, containsAll, isEmpty, remove, retainAll, spliterator
-
Field Details
-
entryIterator
-
-
Constructor Details
-
EntrySet
public EntrySet()
-
-
Method Details
-
iterator
-
size
public int size() -
clear
public void clear() -
contains
-
removeIfInt
Removes all the elements of this collection that satisfy the given predicate.NB: Renamed from removeIf to avoid overloading on parameter types of lambda expression, which doesn't play well with type inference in lambda expressions.
- Parameters:
filter
- a predicate to apply.- Returns:
true
if at least one key was removed.
-
toArray
-
toArray
public <T> T[] toArray(T[] a)
-