|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A Source implements the side of an event queue where QueueElements are dequeued operations only.
The interface design is heavily influenced by Matt Welsh's SandStorm server, his demonstration of the SEDA architecture. We have deviated where we felt the design differences where better.
Field Summary | |
static java.lang.String |
ROLE
|
Method Summary | |
DequeueInterceptor |
getDequeueInterceptor()
Return the dequeue executable for this sink. |
EnqueuePredicate |
getEnqueuePredicate()
Return the enqueue predicate for this sink. |
void |
setDequeueInterceptor(DequeueInterceptor executable)
Set the dequeue executable for this sink. |
void |
setEnqueuePredicate(EnqueuePredicate enqueuePredicate)
Set the enqueue predicate for this sink. |
Methods inherited from interface org.apache.excalibur.event.Source |
dequeue, dequeue, dequeueAll, setTimeout, size |
Methods inherited from interface org.apache.excalibur.event.Sink |
canAccept, enqueue, enqueue, isFull, maxSize, prepareEnqueue, size, tryEnqueue |
Field Detail |
public static final java.lang.String ROLE
Method Detail |
public void setEnqueuePredicate(EnqueuePredicate enqueuePredicate)
Sink.enqueue(Object)
,
which means it must be simple and fast. This can be used
to implement many interesting m_sink-thresholding policies,
such as simple count threshold, credit-based mechanisms,
and more.
enqueuePredicate
- the enqueue predicate for this sinkpublic EnqueuePredicate getEnqueuePredicate()
EnqueuePredicate
the enqueue predicate for this sink.public void setDequeueInterceptor(DequeueInterceptor executable)
executable
- The dequeue executable for this sink.public DequeueInterceptor getDequeueInterceptor()
DequeueInterceptor
The dequeue executable for this sink.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |