public abstract class AbstractMostlySingleton<T> extends Object implements Set<T>
Modifier and Type | Class and Description |
---|---|
static class |
AbstractMostlySingleton.State |
Modifier and Type | Field and Description |
---|---|
protected Collection<T> |
set |
protected AbstractMostlySingleton.State |
state |
protected T |
value |
Constructor and Description |
---|
AbstractMostlySingleton() |
Modifier and Type | Method and Description |
---|---|
boolean |
addAll(Collection<? extends T> c) |
void |
clear() |
boolean |
containsAll(Collection<?> c) |
boolean |
isEmpty() |
Iterator<T> |
iterator() |
boolean |
remove(Object o) |
boolean |
removeAll(Collection<?> c) |
boolean |
retainAll(Collection<?> c) |
int |
size() |
Object[] |
toArray() |
<S> S[] |
toArray(S[] a) |
String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
parallelStream, removeIf, stream
protected AbstractMostlySingleton.State state
protected T value
protected Collection<T> set
public int size()
public boolean isEmpty()
public boolean addAll(Collection<? extends T> c)
public Object[] toArray()
public <S> S[] toArray(S[] a)
public boolean remove(Object o)
public boolean containsAll(Collection<?> c)
containsAll
in interface Collection<T>
containsAll
in interface Set<T>
public boolean retainAll(Collection<?> c)
public boolean removeAll(Collection<?> c)