Class QueueEnqueueImpl
- java.lang.Object
- 
- org.eclipse.ecf.core.sharedobject.util.QueueEnqueueImpl
 
- 
- All Implemented Interfaces:
- IQueueEnqueue
 
 public class QueueEnqueueImpl extends Object implements IQueueEnqueue 
- 
- 
Constructor SummaryConstructors Constructor Description QueueEnqueueImpl(SimpleFIFOQueue impl)
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidenqueue(Event element)Enqueue a given Event onto the underlying queuevoidenqueue(Event[] elements)Enqueue a set of events Event onto the underlying queuevoidenqueue_abort(Object enqueue_key)Abort the commit of a set of Event instances previously prepared viaIQueueEnqueue.enqueue_prepare(Event[])voidenqueue_commit(Object enqueue_key)Commit a set of Event instances previously prepared viaIQueueEnqueue.enqueue_prepare(Event[])booleanenqueue_lossy(Event element)Enqueue the given event with lossy enqueuing.Objectenqueue_prepare(Event[] elements)Prepare an enqueue of a set of Event instances.IEnqueueProcessorgetEnqueueProcessor()Get enqueue processor for this queue.voidsetEnqueueProcessor(IEnqueueProcessor pred)Set enqueue processor for this queue.intsize()Return size of contents in queue
 
- 
- 
- 
Constructor Detail- 
QueueEnqueueImplpublic QueueEnqueueImpl(SimpleFIFOQueue impl) 
 
- 
 - 
Method Detail- 
enqueuepublic void enqueue(Event element) throws QueueException Description copied from interface:IQueueEnqueueEnqueue a given Event onto the underlying queue- Specified by:
- enqueuein interface- IQueueEnqueue
- Parameters:
- element-
- Throws:
- QueueException- not thrown by this implementation.
 
 - 
enqueuepublic void enqueue(Event[] elements) throws QueueException Description copied from interface:IQueueEnqueueEnqueue a set of events Event onto the underlying queue- Specified by:
- enqueuein interface- IQueueEnqueue
- Parameters:
- elements- the Events to enqueue
- Throws:
- QueueException- thrown if events cannot be enqueued
 
 - 
enqueue_preparepublic Object enqueue_prepare(Event[] elements) throws QueueException Description copied from interface:IQueueEnqueuePrepare an enqueue of a set of Event instances. The Object returned should subsequently be used to either commit the prepared enqueue transaction (IQueueEnqueue.enqueue_commit(Object), or to abort the prepared enqueue transactionIQueueEnqueue.enqueue_abort(Object)- Specified by:
- enqueue_preparein interface- IQueueEnqueue
- Parameters:
- elements-
- Returns:
- Object
- Throws:
- QueueException- not thrown by this implementation.
 
 - 
enqueue_commitpublic void enqueue_commit(Object enqueue_key) Description copied from interface:IQueueEnqueueCommit a set of Event instances previously prepared viaIQueueEnqueue.enqueue_prepare(Event[])- Specified by:
- enqueue_commitin interface- IQueueEnqueue
- Parameters:
- enqueue_key- the transaction key previously returned from the call to- IQueueEnqueue.enqueue_prepare(Event[])
 
 - 
enqueue_abortpublic void enqueue_abort(Object enqueue_key) Description copied from interface:IQueueEnqueueAbort the commit of a set of Event instances previously prepared viaIQueueEnqueue.enqueue_prepare(Event[])- Specified by:
- enqueue_abortin interface- IQueueEnqueue
- Parameters:
- enqueue_key- the transaction key previously returned from the call to- IQueueEnqueue.enqueue_prepare(Event[])
 
 - 
enqueue_lossypublic boolean enqueue_lossy(Event element) Description copied from interface:IQueueEnqueueEnqueue the given event with lossy enqueuing.- Specified by:
- enqueue_lossyin interface- IQueueEnqueue
- Parameters:
- element- the event to
- Returns:
- true if enqueued successfully, false if not
 
 - 
setEnqueueProcessorpublic void setEnqueueProcessor(IEnqueueProcessor pred) Description copied from interface:IQueueEnqueueSet enqueue processor for this queue. The given processor, if non-null, will be consulted when and enqueue operation is requested to determine whether the enqueue should occur or not- Specified by:
- setEnqueueProcessorin interface- IQueueEnqueue
- Parameters:
- pred- the IEnqueueProcessor for this queue. Should not be null.
 
 - 
getEnqueueProcessorpublic IEnqueueProcessor getEnqueueProcessor() Description copied from interface:IQueueEnqueueGet enqueue processor for this queue. Returns the enqueue processor previously assigned via theIQueueEnqueue.setEnqueueProcessor(IEnqueueProcessor). Returns null if no enqueue processor previously assigned- Specified by:
- getEnqueueProcessorin interface- IQueueEnqueue
- Returns:
- IEnqueueProcessor previously assigned via
         IQueueEnqueue.setEnqueueProcessor(IEnqueueProcessor)
 
 - 
sizepublic int size() Description copied from interface:IQueueEnqueueReturn size of contents in queue- Specified by:
- sizein interface- IQueueEnqueue
- Returns:
- int size of queue contents. Zero if empty
 
 
- 
 
-