|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mule.util.queue.AbstractQueueStoreDelegate
public abstract class AbstractQueueStoreDelegate
Abstract queue delegate implementation that forces common queue behaviour
| Constructor Summary | |
|---|---|
AbstractQueueStoreDelegate(int capacity)
|
|
| Method Summary | |
|---|---|
protected abstract void |
add(Serializable item)
Adds an item at the end of the queue |
boolean |
addAll(Collection<? extends Serializable> items)
Appends all of the elements in the specified collection to the queue (optional operation). |
protected abstract void |
addFirst(Serializable item)
Adds an object at the beginning of the queue |
void |
clear()
Discards all the elements in the queue |
protected abstract boolean |
doAddAll(Collection<? extends Serializable> items)
Adds all the items at the end of the queue |
protected abstract void |
doClear()
Removes all the items in the queue |
protected abstract Serializable |
getFirst()
reads the first element in the queue |
int |
getSize()
Return the size of the queue |
protected abstract boolean |
isEmpty()
|
boolean |
offer(Serializable o,
int room,
long timeout)
Offer to append a new member to the end of the queue |
Serializable |
peek()
return, but do not remove, the first member of the queue |
Serializable |
poll(long timeout)
Poll the queue for its first member, and, if there is one, remove and return it |
void |
putNow(Serializable o)
append a new member to the end of the queue |
protected abstract Serializable |
removeFirst()
removes the first element in the queue |
protected abstract int |
size()
|
void |
untake(Serializable item)
Restore a previously removed member to the front of the queue |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.mule.util.queue.QueueStoreDelegate |
|---|
dispose |
| Constructor Detail |
|---|
public AbstractQueueStoreDelegate(int capacity)
| Method Detail |
|---|
public final void putNow(Serializable o)
QueueStoreDelegate
putNow in interface QueueStoreDelegate
public final boolean offer(Serializable o,
int room,
long timeout)
throws InterruptedException
QueueStoreDelegate
offer in interface QueueStoreDelegateInterruptedException
public final Serializable poll(long timeout)
throws InterruptedException
QueueStoreDelegate
poll in interface QueueStoreDelegateInterruptedException
public final Serializable peek()
throws InterruptedException
QueueStoreDelegate
peek in interface QueueStoreDelegateInterruptedException
public final void untake(Serializable item)
throws InterruptedException
QueueStoreDelegate
untake in interface QueueStoreDelegateInterruptedException
public final void clear()
throws InterruptedException
QueueStoreDelegate
clear in interface QueueStoreDelegateInterruptedExceptionpublic final boolean addAll(Collection<? extends Serializable> items)
QueueStoreDelegate
addAll in interface QueueStoreDelegateitems - to be added to the queue
public int getSize()
QueueStoreDelegate
getSize in interface QueueStoreDelegateprotected abstract int size()
protected abstract Serializable getFirst()
throws InterruptedException
InterruptedException
protected abstract Serializable removeFirst()
throws InterruptedException
InterruptedExceptionprotected abstract void add(Serializable item)
item - object to add
protected abstract void addFirst(Serializable item)
throws InterruptedException
item - object to add
InterruptedExceptionprotected abstract boolean doAddAll(Collection<? extends Serializable> items)
items - objects to add
protected abstract void doClear()
protected abstract boolean isEmpty()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||