Class OpenHashSet<T>
java.lang.Object
io.reactivex.rxjava3.internal.util.OpenHashSet<T>
- Type Parameters:
T
- the element type
A simple open hash set with add, remove and clear capabilities only.
Doesn't support nor checks for null
s.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionOpenHashSet
(int capacity) Creates an OpenHashSet with the initial capacity and load factor of 0.75f.OpenHashSet
(int capacity, float loadFactor) -
Method Summary
-
Field Details
-
INT_PHI
private static final int INT_PHI- See Also:
-
loadFactor
final float loadFactor -
mask
int mask -
size
int size -
maxSize
int maxSize -
keys
T[] keys
-
-
Constructor Details
-
OpenHashSet
public OpenHashSet() -
OpenHashSet
public OpenHashSet(int capacity) Creates an OpenHashSet with the initial capacity and load factor of 0.75f.- Parameters:
capacity
- the initial capacity
-
OpenHashSet
public OpenHashSet(int capacity, float loadFactor)
-
-
Method Details
-
add
-
remove
-
removeEntry
-
rehash
void rehash() -
mix
static int mix(int x) -
keys
-
size
public int size()
-