|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
E
- public interface BaseQueue<E>
Base interface for Hazelcast distributed queues.
BlockingQueue
,
IQueue
,
TransactionalQueue
Method Summary | |
---|---|
boolean |
offer(E e)
Inserts the specified element into this queue if it is possible to do so immediately without violating capacity restrictions, returning true upon success and false if no space is currently available. |
boolean |
offer(E e,
long timeout,
TimeUnit unit)
Inserts the specified element into this queue, waiting up to the specified wait time if necessary for space to become available. |
E |
poll()
Retrieves and removes the head of this queue, or returns null if this queue is empty. |
E |
poll(long timeout,
TimeUnit unit)
Retrieves and removes the head of this queue, waiting up to the specified wait time if necessary for an element to become available. |
int |
size()
Returns the number of elements in this collection. |
Methods inherited from interface com.hazelcast.core.DistributedObject |
---|
destroy, getId, getName, getPartitionKey, getServiceName |
Method Detail |
---|
boolean offer(E e)
e
- the element to add
boolean offer(E e, long timeout, TimeUnit unit) throws InterruptedException
e
- the element to addtimeout
- how long to wait before giving up, in units of
unitunit
- a TimeUnit determining how to interpret the
timeout parameter
InterruptedException
- if interrupted while waitingE poll()
E poll(long timeout, TimeUnit unit) throws InterruptedException
timeout
- how long to wait before giving up, in units of
unitunit
- a TimeUnit determining how to interpret the
timeout parameter
InterruptedException
- if interrupted while waitingint size()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |