|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectseda.sandStorm.core.SimpleSink
public abstract class 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 |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SimpleSink()
| Method Detail |
|---|
public abstract void enqueue(QueueElementIF enqueueMe)
throws SinkException
enqueue in interface SinkIFenqueueMe - The QueueElementIF to enqueue
SinkFullException - Indicates that the sink is temporarily full.
SinkClosedException - Indicates that the sink is
no longer being serviced.
SinkExceptionpublic boolean enqueue_lossy(QueueElementIF enqueueMe)
enqueue_lossy in interface SinkIFenqueueMe - The QueueElementIF to enqueue
public void enqueue_many(QueueElementIF[] enqueueMe)
throws SinkException
enqueue_many in interface SinkIFenqueueMe - The element array to enqueue
SinkFullException - Indicates that the sink is temporarily full.
SinkClosedException - Indicates that the sink is
no longer being serviced.
SinkExceptionpublic java.lang.Object enqueue_prepare(QueueElementIF[] enqueueMe)
throws SinkException
enqueue_prepare in interface SinkIFenqueueMe - The element array to provisionally enqueue
SinkFullException - 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.
SinkExceptionenqueue_commit,
enqueue_abortpublic void enqueue_commit(java.lang.Object key)
enqueue_commit in interface SinkIFpublic void enqueue_abort(java.lang.Object key)
enqueue_abort in interface SinkIFpublic 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
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||