Adds given item to the end of the queue. Operation is successful only if queue has required capacity.
element to add.
true
.
Adds all items in the specified item array to this queue. If items array changes during this operation, behaviour is unspecified.
items to be added.
true
if this queue changed, false
otherwise.
Adds an item listener for this queue. Listener will be invoked for any add/remove item events.
true
if updated item should be included in the event.
Registration id of the listener.
Removes all of the elements in this queue.
Returns true
if this queue contains the given item.
true
if this queue contains the item, false
otherwise.
Checks if this queue contains all of the items in given array.
true
if thi queue contains all items, false
otherwise.
Destroys this object cluster-wide. Clears all resources taken for this object.
Removes all items in this queue and add them to the end of given arr
.
maximum number of elements that would be moved.
number of items moved from this queue to the array.
Returns the unique name of this object.
Returns the key of the partition that this DistributedObject is assigned to.
For a partitioned data structure, the returned value will not be null
,
but otherwise undefined
.
Returns the service name for this object.
Checks if this queue contains any element.
true
if number of elements in this queue is 0.
Inserts given item at the end of the queue if there is room. If queue capacity is full, offer operation fails.
if specified, operation waits for time
milliseconds for
space to become available before returning false.
true
if the item is successfully added, false
otherwise.
Retrieves, but does not remove the head of this queue.
the head of this queue or null
if the queue is empty.
Retrieves and removes the top of this queue.
operation waits upto time
milliseconds if this queue is empty. The default value of this parameter is 0
,
which means no waiting.
the head of this queue or null
if no element is available.
Inserts the item at the end of this queue. It waits to return until space becomes available if necessary.
Returns the number of additional items, this queue can contain.
remaining capacity or Integer.MAX_VALUE
at server side.
Removes an instance of given item from this queue.
true
if this queue changed, false
otherwise.
Removes all items in given items
from this queue.
true
if this queue changed, false
otherwise.
Removes an item listener for this queue.
Registration id of the listener to be removed.
true
if the item listener is removed, false
otherwise.
Retains only the items that are present it given items
.
true
if this queue changed, false
otherwise.
Returns the number of items in this queue.
number of items or Integer.MAX_VALUE
if number of elements is more than Integer.MAX_VALUE
on server side.
Retrieves and removes the head of this queue, waiting if necessary until an element becomes available.
head of the queue.
Returns an array that contains all items of this queue in proper sequence.
Generated using TypeDoc
Concurrent, distributed, observable queue.
Methods that require serialization/deserialization may throw RangeError, e.g when there is no suitable serializer for a certain type.