public class OpenLongHashSet extends OpenAbstractCollection
FREE, freeEntries, FULL, REMOVED, state, tabledefaultCapacity, defaultMaxLoadFactor, defaultMinLoadFactor, distinct, highWaterMark, lowWaterMark, maxLoadFactor, minLoadFactor| Constructor and Description |
|---|
OpenLongHashSet()
Constructs an empty map with default capacity and default load factors.
|
OpenLongHashSet(int initialCapacity)
Constructs an empty map with the specified initial capacity and default
load factors.
|
OpenLongHashSet(int initialCapacity,
double minLoadFactor,
double maxLoadFactor)
Constructs an empty map with the specified initial capacity and the
specified minimum and maximum load factor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
Removes all (key,value) associations from the receiver.
|
Object |
clone()
Returns a deep copy of the receiver.
|
void |
keys(LongArrayList list)
Fills all keys contained in the receiver into the specified list.
|
boolean |
put(long key)
Associates the given key with the given value.
|
protected void |
rehash(int newCapacity)
Rehashes the contents of the receiver into a new table with a smaller or
larger capacity.
|
boolean |
removeKey(long key)
Removes the given key with its associated element from the receiver, if
present.
|
protected void |
setUp(int initialCapacity,
double minLoadFactor,
double maxLoadFactor)
Initializes the receiver.
|
containsKey, ensureCapacity, forEachKey, indexOfInsertion, indexOfKey, trimToSizechooseGrowCapacity, chooseHighWaterMark, chooseLowWaterMark, chooseMeanCapacity, chooseShrinkCapacity, isEmpty, nextPrime, sizepublic OpenLongHashSet()
public OpenLongHashSet(int initialCapacity)
initialCapacity - the initial capacity of the map.public OpenLongHashSet(int initialCapacity,
double minLoadFactor,
double maxLoadFactor)
initialCapacity - the initial capacity.minLoadFactor - the minimum load factor.maxLoadFactor - the maximum load factor.public final void clear()
clear in class AbstractMappublic final Object clone()
clone in class PersistentObjectpublic final void keys(LongArrayList list)
OpenAbstractCollection.forEachKey(LongProcedure).
This method can be used to iterate over the keys of the receiver.
list - the list to be filled, can have any size.public final boolean put(long key)
key - the key the value shall be associated with.protected final void rehash(int newCapacity)
newCapacity - the new capacitypublic final boolean removeKey(long key)
key - the key to be removed from the receiver.protected final void setUp(int initialCapacity,
double minLoadFactor,
double maxLoadFactor)
setUp in class AbstractMapinitialCapacity - the initial capacity of the receiver.minLoadFactor - the minLoadFactor of the receiver.maxLoadFactor - the maxLoadFactor of the receiver.Copyright © 2019 TomTom International B.V.. All rights reserved.