T - the generic typepublic class LimitedSizeQueue<T> extends Object implements Queue<T>
| Constructor and Description |
|---|
LimitedSizeQueue()
Instantiates a new limited size queue.
|
LimitedSizeQueue(int maxSize)
Instantiates a new limited size queue.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(T e)
Adds the.
|
boolean |
addAll(Collection<? extends T> c)
Adds the all.
|
void |
clear()
Clear.
|
boolean |
contains(Object o)
Contains.
|
boolean |
containsAll(Collection<?> c)
Contains all.
|
T |
element()
Element.
|
boolean |
isEmpty()
Checks if is empty.
|
Iterator<T> |
iterator()
Iterator.
|
int |
maximumSize()
Maximum size.
|
boolean |
offer(T e)
Offer.
|
T |
peek()
Peek.
|
T |
poll()
Poll.
|
T |
remove()
Removes the.
|
boolean |
remove(Object o)
Removes the.
|
boolean |
removeAll(Collection<?> c)
Removes the all.
|
boolean |
retainAll(Collection<?> c)
Retain all.
|
int |
size()
Size.
|
Object[] |
toArray()
To array.
|
<T> T[] |
toArray(T[] a)
To array.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitequals, hashCode, parallelStream, removeIf, spliterator, streampublic LimitedSizeQueue()
public LimitedSizeQueue(int maxSize)
maxSize - the max sizepublic int maximumSize()
public int size()
size in interface Collection<T>Collection.size()public boolean isEmpty()
isEmpty in interface Collection<T>Collection.isEmpty()public boolean contains(Object o)
contains in interface Collection<T>o - the oCollection.contains(java.lang.Object)public Iterator<T> iterator()
iterator in interface Iterable<T>iterator in interface Collection<T>Collection.iterator()public Object[] toArray()
toArray in interface Collection<T>Collection.toArray()public <T> T[] toArray(T[] a)
toArray in interface Collection<T>T - the generic typea - the aCollection.toArray(java.lang.Object[])public boolean remove(Object o)
remove in interface Collection<T>o - the oCollection.remove(java.lang.Object)public boolean containsAll(Collection<?> c)
containsAll in interface Collection<T>c - the cCollection.containsAll(java.util.Collection)public boolean addAll(Collection<? extends T> c)
addAll in interface Collection<T>c - the cCollection.addAll(java.util.Collection)public boolean removeAll(Collection<?> c)
removeAll in interface Collection<T>c - the cCollection.removeAll(java.util.Collection)public boolean retainAll(Collection<?> c)
retainAll in interface Collection<T>c - the cCollection.retainAll(java.util.Collection)public void clear()
clear in interface Collection<T>Collection.clear()public boolean add(T e)
add in interface Collection<T>add in interface Queue<T>e - the eQueue.add(java.lang.Object)public boolean offer(T e)
offer in interface Queue<T>e - the eQueue.offer(java.lang.Object)public T remove()
remove in interface Queue<T>Queue.remove()public T poll()
poll in interface Queue<T>Queue.poll()public T element()
element in interface Queue<T>Queue.element()public T peek()
peek in interface Queue<T>Queue.peek()Copyright © 2019 Fraunhofer IPA. All rights reserved.