Class QueueEnqueueImpl
java.lang.Object
org.eclipse.ecf.core.sharedobject.util.QueueEnqueueImpl
- All Implemented Interfaces:
IQueueEnqueue
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidEnqueue a given Event onto the underlying queuevoidEnqueue 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.enqueue_prepare(Event[] elements) Prepare an enqueue of a set of Event instances.Get enqueue processor for this queue.voidSet enqueue processor for this queue.intsize()Return size of contents in queue
-
Constructor Details
-
Method Details
-
enqueue
Description copied from interface:IQueueEnqueueEnqueue a given Event onto the underlying queue- Specified by:
enqueuein interfaceIQueueEnqueue- Parameters:
element-- Throws:
QueueException- not thrown by this implementation.
-
enqueue
Description copied from interface:IQueueEnqueueEnqueue a set of events Event onto the underlying queue- Specified by:
enqueuein interfaceIQueueEnqueue- Parameters:
elements- the Events to enqueue- Throws:
QueueException- thrown if events cannot be enqueued
-
enqueue_prepare
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 interfaceIQueueEnqueue- Parameters:
elements-- Returns:
- Object
- Throws:
QueueException- not thrown by this implementation.
-
enqueue_commit
Description copied from interface:IQueueEnqueueCommit a set of Event instances previously prepared viaIQueueEnqueue.enqueue_prepare(Event[])- Specified by:
enqueue_commitin interfaceIQueueEnqueue- Parameters:
enqueue_key- the transaction key previously returned from the call toIQueueEnqueue.enqueue_prepare(Event[])
-
enqueue_abort
Description copied from interface:IQueueEnqueueAbort the commit of a set of Event instances previously prepared viaIQueueEnqueue.enqueue_prepare(Event[])- Specified by:
enqueue_abortin interfaceIQueueEnqueue- Parameters:
enqueue_key- the transaction key previously returned from the call toIQueueEnqueue.enqueue_prepare(Event[])
-
enqueue_lossy
Description copied from interface:IQueueEnqueueEnqueue the given event with lossy enqueuing.- Specified by:
enqueue_lossyin interfaceIQueueEnqueue- Parameters:
element- the event to- Returns:
- true if enqueued successfully, false if not
-
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 interfaceIQueueEnqueue- Returns:
- IEnqueueProcessor previously assigned via
IQueueEnqueue.setEnqueueProcessor(IEnqueueProcessor)
-
size
public int size()Description copied from interface:IQueueEnqueueReturn size of contents in queue- Specified by:
sizein interfaceIQueueEnqueue- Returns:
- int size of queue contents. Zero if empty
-