@Generated(date="2015-05-05T11:00:03+0200", value="KTypeScatterSet.java") public class IntScatterSet extends IntHashSet
IntHashSet
but does not implement per-instance key mixing
strategy and uses a simpler (faster) bit distribution function.
Note: read about important differences between hash and scatter sets.
IntHashSet
,
HPPC interfaces diagramIntHashSet.EntryIterator
assigned, hasEmptyKey, keyMixer, keys, loadFactor, mask, orderMixer, resizeAt
Constructor and Description |
---|
IntScatterSet()
New instance with sane defaults.
|
IntScatterSet(int expectedElements)
New instance with sane defaults.
|
IntScatterSet(int expectedElements,
double loadFactor)
New instance with sane defaults.
|
Modifier and Type | Method and Description |
---|---|
protected int |
hashKey(int key)
Returns a hash code for the given key.
|
int |
removeAll(IntLookupContainer c)
Default implementation uses a predicate for removal.
|
int |
retainAll(IntLookupContainer c)
Default implementation uses a predicate for retaining.
|
int |
retainAll(IntPredicate predicate)
Default implementation redirects to
IntCollection.removeAll(IntPredicate) and
negates the predicate. |
java.lang.String |
toString()
Convert the contents of this container to a human-friendly string.
|
add, addAll, addAll, addAll, allocateBuffers, allocateThenInsertThenRehash, clear, clone, contains, ensureCapacity, equals, forEach, forEach, from, hashCode, indexExists, indexGet, indexInsert, indexOf, indexReplace, isEmpty, iterator, rehash, release, remove, removeAll, removeAll, shiftConflictingKeys, size, toArray, verifyLoadFactor
finalize, getClass, notify, notifyAll, wait, wait, wait
removeAll, retainAll, retainAll
public IntScatterSet()
public IntScatterSet(int expectedElements)
public IntScatterSet(int expectedElements, double loadFactor)
protected int hashKey(int key)
IntHashSet
IntHashSet.keyMixer
to differentiate hash order of keys between hash containers. Helps
alleviate problems resulting from linear conflict resolution in open
addressing.
The output from this function should evenly distribute keys across the
entire integer range.hashKey
in class IntHashSet
public int removeAll(IntLookupContainer c)
removeAll
in interface IntCollection
public int retainAll(IntLookupContainer c)
retainAll
in interface IntCollection
public int retainAll(IntPredicate predicate)
IntCollection.removeAll(IntPredicate)
and
negates the predicate.retainAll
in interface IntCollection
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2015 Carrot Search s.c.. All Rights Reserved.