public class QueueImpl<T> extends Object implements IQueue<T>
| Modifier and Type | Method and Description |
|---|---|
void |
addListener(IQueueListener listener)
Adds a queue listener to the queue.
|
int |
getElementCount()
Returns the number of elements in the queue.
|
boolean |
hasElements()
Returns true if the queue contains elements.
|
T |
nextElement()
Returns the nextElement from the queue, removes the element from
the queue afterwards.
|
void |
putElement(T o)
Puts a new element in the queue.
|
void |
removeListener(IQueueListener listener)
Removes a queue listener from the queue.
|
int |
size()
Returns the size of the queue.
|
String |
toString() |
public void addListener(IQueueListener listener)
IQueueaddListener in interface IQueue<T>public int getElementCount()
IQueuegetElementCount in interface IQueue<T>public int size()
IQueuepublic boolean hasElements()
IQueuehasElements in interface IQueue<T>public T nextElement()
IQueuenextElement in interface IQueue<T>public void putElement(T o) throws QueueOverflowException
putElement in interface IQueue<T>o - QueueOverflowException - if the queue is full.public void removeListener(IQueueListener listener)
IQueueremoveListener in interface IQueue<T>Copyright © 2010-2014 anotheria.net. All Rights Reserved.