Package com.carrotsearch.hppc
Class AbstractShortCollection
java.lang.Object
com.carrotsearch.hppc.AbstractShortCollection
- All Implemented Interfaces:
ShortCollection
,ShortContainer
,Iterable<ShortCursor>
- Direct Known Subclasses:
ByteShortHashMap.ValuesContainer
,CharShortHashMap.ValuesContainer
,DoubleShortHashMap.ValuesContainer
,FloatShortHashMap.ValuesContainer
,IntShortHashMap.ValuesContainer
,LongShortHashMap.ValuesContainer
,ObjectShortHashMap.ValuesContainer
,ShortArrayDeque
,ShortArrayList
,ShortByteHashMap.KeysContainer
,ShortCharHashMap.KeysContainer
,ShortDoubleHashMap.KeysContainer
,ShortFloatHashMap.KeysContainer
,ShortHashSet
,ShortIntHashMap.KeysContainer
,ShortLongHashMap.KeysContainer
,ShortObjectHashMap.KeysContainer
,ShortShortHashMap.KeysContainer
,ShortShortHashMap.ValuesContainer
@Generated(date="2023-10-26T04:33:10+0000",
value="AbstractKTypeCollection.java")
abstract class AbstractShortCollection
extends Object
implements ShortCollection
Common superclass for collections.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionint
Default implementation uses a predicate for removal.int
retainAll
(ShortPredicate predicate) Default implementation redirects toShortCollection.removeAll(ShortPredicate)
and negates the predicate.int
Default implementation uses a predicate for retaining.short[]
toArray()
Default implementation of copying to an array.toString()
Convert the contents of this container to a human-friendly string.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface com.carrotsearch.hppc.ShortCollection
clear, release, removeAll, removeAll
-
Constructor Details
-
AbstractShortCollection
AbstractShortCollection()
-
-
Method Details
-
removeAll
Default implementation uses a predicate for removal.- Specified by:
removeAll
in interfaceShortCollection
- Returns:
- Returns the number of removed elements.
-
retainAll
Default implementation uses a predicate for retaining.- Specified by:
retainAll
in interfaceShortCollection
- Returns:
- Returns the number of removed elements.
-
retainAll
Default implementation redirects toShortCollection.removeAll(ShortPredicate)
and negates the predicate.- Specified by:
retainAll
in interfaceShortCollection
- Returns:
- Returns the number of removed elements.
-
toArray
public short[] toArray()Default implementation of copying to an array.- Specified by:
toArray
in interfaceShortContainer
-
toString
Convert the contents of this container to a human-friendly string.
-