public class WeakHashSet<E> extends AbstractSet<E>
WeakReference
so that contained objects can be collected
by the GC.Constructor and Description |
---|
WeakHashSet() |
WeakHashSet(Collection<E> c) |
WeakHashSet(int initialCapacity) |
WeakHashSet(int initialCapacity,
float loadFactor) |
Modifier and Type | Method and Description |
---|---|
boolean |
add(E o) |
void |
clear() |
boolean |
contains(Object o) |
boolean |
isEmpty() |
Iterator<E> |
iterator() |
boolean |
remove(Object o) |
int |
size() |
equals, hashCode, removeAll
addAll, containsAll, retainAll, toArray, toArray, toString
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
addAll, containsAll, retainAll, spliterator, toArray, toArray
parallelStream, removeIf, stream
public WeakHashSet()
public WeakHashSet(Collection<E> c)
public WeakHashSet(int initialCapacity, float loadFactor)
public WeakHashSet(int initialCapacity)
public Iterator<E> iterator()
iterator
in interface Iterable<E>
iterator
in interface Collection<E>
iterator
in interface Set<E>
iterator
in class AbstractCollection<E>
Collection.iterator()
public int size()
size
in interface Collection<E>
size
in interface Set<E>
size
in class AbstractCollection<E>
Collection.size()
public boolean isEmpty()
isEmpty
in interface Collection<E>
isEmpty
in interface Set<E>
isEmpty
in class AbstractCollection<E>
public boolean contains(Object o)
contains
in interface Collection<E>
contains
in interface Set<E>
contains
in class AbstractCollection<E>
Collection.contains(java.lang.Object)
public boolean add(E o)
add
in interface Collection<E>
add
in interface Set<E>
add
in class AbstractCollection<E>
Collection.add(java.lang.Object)
public boolean remove(Object o)
remove
in interface Collection<E>
remove
in interface Set<E>
remove
in class AbstractCollection<E>
Set.remove(java.lang.Object)
public void clear()
clear
in interface Collection<E>
clear
in interface Set<E>
clear
in class AbstractCollection<E>
Collection.clear()
Copyright © GigaSpaces.