public abstract class AbstractWaitlist<CollectionT extends java.util.Collection<AbstractState>> extends java.lang.Object implements Waitlist
| Modifier and Type | Field and Description |
|---|---|
protected CollectionT |
waitlist |
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractWaitlist(CollectionT waitList)
Create a waitlist from a carrier collection.
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(AbstractState abstractState)
Adds an abstract state.
|
void |
addAll(java.util.Collection<? extends AbstractState> abstractStates)
Adds multiple abstract states.
|
void |
clear()
Empties the waitlist.
|
boolean |
contains(AbstractState abstractState)
Checks whether the abstract state is present.
|
void |
forEach(java.util.function.Consumer<? super AbstractState> action) |
boolean |
isEmpty()
Checks whether the waitlist is empty.
|
java.util.Iterator<AbstractState> |
iterator() |
boolean |
remove(AbstractState abstractState)
Removes an abstract state.
|
void |
removeAll(java.util.Collection<?> abstractStates)
Removes multiple abstract states.
|
int |
size()
Returns the size of the waitlist.
|
java.util.Spliterator<AbstractState> |
spliterator() |
protected final CollectionT extends java.util.Collection<AbstractState> waitlist
protected AbstractWaitlist(CollectionT waitList)
waitList - the carrier collectionpublic void add(AbstractState abstractState)
Waitlistpublic void addAll(java.util.Collection<? extends AbstractState> abstractStates)
Waitlistpublic void clear()
Waitlistpublic boolean contains(AbstractState abstractState)
Waitlistpublic boolean isEmpty()
Waitlistpublic boolean remove(AbstractState abstractState)
Waitlistpublic void removeAll(java.util.Collection<?> abstractStates)
Waitlistpublic int size()
Waitlist@NotNull public java.util.Iterator<AbstractState> iterator()
iterator in interface java.lang.Iterable<AbstractState>public void forEach(java.util.function.Consumer<? super AbstractState> action)
forEach in interface java.lang.Iterable<AbstractState>public java.util.Spliterator<AbstractState> spliterator()
spliterator in interface java.lang.Iterable<AbstractState>