|
More information: http://www.cs.berkeley.edu/~mdw/proj/seda/ | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--seda.sandStorm.core.SimpleSink
The SimpleSink class is an abstract class which implements 'null' functionality for most of the administrative methods of SinkIF. This class can be extended to implement simple SinkIF's which don't require most of the special behavior of the fully general case.
SinkIF| Constructor Summary | |
SimpleSink()
|
|
| Method Summary | |
void |
enqueue_abort(java.lang.Object key)
Not supported; throws an IllegalArgumentException. |
void |
enqueue_commit(java.lang.Object key)
Not supported; throws an IllegalArgumentException. |
boolean |
enqueue_lossy(QueueElementIF enqueueMe)
Calls enqueue() and returns false if SinkException occurs. |
void |
enqueue_many(QueueElementIF[] enqueueMe)
Simply calls enqueue() on each item in the array. |
java.lang.Object |
enqueue_prepare(QueueElementIF[] enqueueMe)
Not supported; throws an IllegalArgumentException. |
abstract void |
enqueue(QueueElementIF enqueueMe)
Must be implemented by subclasses. |
EnqueuePredicateIF |
getEnqueuePredicate()
Returns null. |
int |
profileSize()
Returns size. |
void |
setEnqueuePredicate(EnqueuePredicateIF pred)
Not supported; throws an IllegalArgumentException. |
int |
size()
Returns 0. |
| Methods inherited from class java.lang.Object |
|
| Constructor Detail |
public SimpleSink()
| Method Detail |
public abstract void enqueue(QueueElementIF enqueueMe)
throws SinkException
enqueue in interface SinkIFseda.sandStorm.api.SinkIFelement - The QueueElementIF to enqueueSinkFullException - Indicates that the sink is temporarily full.SinkClosedException - Indicates that the sink is
no longer being serviced.public boolean enqueue_lossy(QueueElementIF enqueueMe)
enqueue_lossy in interface SinkIFseda.sandStorm.api.SinkIFelement - The QueueElementIF to enqueue
public void enqueue_many(QueueElementIF[] enqueueMe)
throws SinkException
enqueue_many in interface SinkIFseda.sandStorm.api.SinkIFelements - The element array to enqueueSinkFullException - Indicates that the sink is temporarily full.SinkClosedException - Indicates that the sink is
no longer being serviced.
public java.lang.Object enqueue_prepare(QueueElementIF[] enqueueMe)
throws SinkException
enqueue_prepare in interface SinkIFseda.sandStorm.api.SinkIFelements - The element array to provisionally enqueueSinkFullException - Indicates that the sink is temporarily full
and that the requested elements could not be provisionally enqueued.SinkClosedException - Indicates that the sink is
no longer being serviced.enqueue_commit,
enqueue_abortpublic void enqueue_commit(java.lang.Object key)
enqueue_commit in interface SinkIFseda.sandStorm.api.SinkIFkey - The enqueue key returned by a previous call to
enqueue_prepare().java.lang.IllegalArgumentException - Thrown if an unknown enqueue key
is provided.public void enqueue_abort(java.lang.Object key)
enqueue_abort in interface SinkIFseda.sandStorm.api.SinkIFkey - The enqueue key returned by a previous call to
enqueue_prepare().java.lang.IllegalArgumentException - Thrown if an unknown enqueue key
is provided.public void setEnqueuePredicate(EnqueuePredicateIF pred)
setEnqueuePredicate in interface SinkIFpublic EnqueuePredicateIF getEnqueuePredicate()
getEnqueuePredicate in interface SinkIFpublic int size()
size in interface SinkIFpublic int profileSize()
profileSize in interface ProfilableIF
|
More information: http://www.cs.berkeley.edu/~mdw/proj/seda/ | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||