E - the element typepublic class ConcurrentReferenceHashSet<E> extends MapDelegateSet<E>
| Modifier and Type | Field and Description |
|---|---|
private static long |
serialVersionUID
The serialVersionUID
|
| Constructor and Description |
|---|
ConcurrentReferenceHashSet()
Creates a new, empty set with a default initial capacity (16),
reference types (weak keys, strong values), default
load factor (0.75) and concurrencyLevel (16).
|
ConcurrentReferenceHashSet(ConcurrentReferenceHashMap.ReferenceType type)
Creates a new, empty reference set with the specified key
and value reference types.
|
ConcurrentReferenceHashSet(ConcurrentReferenceHashMap.ReferenceType type,
java.util.EnumSet<ConcurrentReferenceHashMap.Option> options)
Creates a new, empty reference set with the specified reference types
and behavioral options.
|
ConcurrentReferenceHashSet(int initialCapacity)
Creates a new, empty set with the specified initial capacity,
and with default reference types (weak keys, strong values),
load factor (0.75) and concurrencyLevel (16).
|
ConcurrentReferenceHashSet(int initialCapacity,
ConcurrentReferenceHashMap.ReferenceType type)
Creates a new, empty set with the specified initial capacity,
reference type and with default load factor (0.75) and concurrencyLevel (16).
|
ConcurrentReferenceHashSet(int initialCapacity,
float loadFactor)
Creates a new, empty set with the specified initial capacity
and load factor and with the default reference types (weak keys,
strong values), and concurrencyLevel (16).
|
ConcurrentReferenceHashSet(int initialCapacity,
float loadFactor,
int concurrencyLevel)
Creates a new, empty set with the specified initial
capacity, load factor and concurrency level.
|
ConcurrentReferenceHashSet(java.util.Set<? extends E> s)
Creates a new set with the same contents as the given set.
|
add, clear, contains, isEmpty, iterator, remove, size, toStringaddAll, containsAll, retainAll, toArray, toArrayclone, finalize, getClass, notify, notifyAll, wait, wait, waitprivate static final long serialVersionUID
public ConcurrentReferenceHashSet(int initialCapacity,
float loadFactor,
int concurrencyLevel)
initialCapacity - the initial capacity. The implementation
performs internal sizing to accommodate this many elements.loadFactor - the load factor threshold, used to control resizing.
Resizing may be performed when the average number of elements per
bin exceeds this threshold.concurrencyLevel - the estimated number of concurrently
updating threads. The implementation performs internal sizing
to try to accommodate this many threads.java.lang.IllegalArgumentException - if the initial capacity is
negative or the load factor or concurrencyLevel are
nonpositive.public ConcurrentReferenceHashSet(int initialCapacity,
float loadFactor)
initialCapacity - The implementation performs internal
sizing to accommodate this many elements.loadFactor - the load factor threshold, used to control resizing.
Resizing may be performed when the average number of elements per
bin exceeds this threshold.java.lang.IllegalArgumentException - if the initial capacity of
elements is negative or the load factor is nonpositivepublic ConcurrentReferenceHashSet(int initialCapacity,
ConcurrentReferenceHashMap.ReferenceType type)
initialCapacity - the initial capacity. The implementation
performs internal sizing to accommodate this many elements.type - the reference type to usejava.lang.IllegalArgumentException - if the initial capacity of
elements is negative.public ConcurrentReferenceHashSet(ConcurrentReferenceHashMap.ReferenceType type)
type - the reference type to usejava.lang.IllegalArgumentException - if the initial capacity of
elements is negative.public ConcurrentReferenceHashSet(ConcurrentReferenceHashMap.ReferenceType type, java.util.EnumSet<ConcurrentReferenceHashMap.Option> options)
type - the reference type to useoptions - the optionsjava.lang.IllegalArgumentException - if the initial capacity of
elements is negative.public ConcurrentReferenceHashSet(int initialCapacity)
initialCapacity - the initial capacity. The implementation
performs internal sizing to accommodate this many elements.java.lang.IllegalArgumentException - if the initial capacity of
elements is negative.public ConcurrentReferenceHashSet()
public ConcurrentReferenceHashSet(java.util.Set<? extends E> s)
s - the set