Top Description Fields Constructors Methods
io.reactivex.internal.util

public final Class OpenHashSet<T>

extends Object
Class Inheritance
Type Parameters
<T>
the element type

A simple open hash set with add, remove and clear capabilities only.

Doesn't support nor checks for nulls.

Field Summary

Modifier and TypeField and Description
private static final int
pack-priv T[]
pack-priv final float
pack-priv int
pack-priv int
pack-priv int

Constructor Summary

AccessConstructor and Description
public
public
OpenHashSet(int
the initial capacity
capacity
)

Creates an OpenHashSet with the initial capacity and load factor of 0.75f.

public
OpenHashSet(int capacity, float loadFactor)

Method Summary

Modifier and TypeMethod and Description
public boolean
add(T value)

public Object[]
keys()

pack-priv static int
mix(int x)

pack-priv void
public boolean
remove(T value)

pack-priv boolean
removeEntry(int pos, T[] a, int m)

public int
size()

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

INT_PHIback to summary
private static final int INT_PHI
keysback to summary
pack-priv T[] keys
loadFactorback to summary
pack-priv final float loadFactor
maskback to summary
pack-priv int mask
maxSizeback to summary
pack-priv int maxSize
sizeback to summary
pack-priv int size

Constructor Detail

OpenHashSetback to summary
public OpenHashSet()
OpenHashSetback to summary
public OpenHashSet(int capacity)

Creates an OpenHashSet with the initial capacity and load factor of 0.75f.

Parameters
capacity:int

the initial capacity

OpenHashSetback to summary
public OpenHashSet(int capacity, float loadFactor)
Annotations
@SuppressWarnings:unchecked

Method Detail

addback to summary
public boolean add(T value)
keysback to summary
public Object[] keys()
mixback to summary
pack-priv static int mix(int x)
rehashback to summary
pack-priv void rehash()
Annotations
@SuppressWarnings:unchecked
removeback to summary
public boolean remove(T value)
removeEntryback to summary
pack-priv boolean removeEntry(int pos, T[] a, int m)
sizeback to summary
public int size()