Returns the available number of entries in the queue.
Returns the available number of entries in the queue.
Always Int.MaxValue
when the queue is unbounded.
Like dequeue1
but provides a way to cancel the dequeue.
Dequeue one A
from this queue.
Dequeue one A
from this queue. Completes once one is ready.
Enqueues one element in this Queue
.
Enqueues one element in this Queue
.
If the queue is full
this waits until queue is empty.
This completes after a
has been successfully enqueued to this Queue
Returns true
when the queue has reached its upper size bound.
Returns true
when the queue has reached its upper size bound.
Always false
when the queue is unbounded.
Offers one element in this Queue
.
Offers one element in this Queue
.
Evaluates to false
if the queue is full, indicating the a
was not queued up.
Evaluates to true
if the a
was queued up successfully.
A
to enqueue
The time-varying size of this Queue
.
The time-varying size of this Queue
. This signal refreshes
only when size changes. Offsetting enqueues and de-queues may
not result in refreshes.
The size bound on the queue.
The size bound on the queue. None
if the queue is unbounded.
Repeatedly call dequeue1
forever.
Enqueues each element of the input stream to this Queue
by
calling enqueue1
on each element.
Returns an alternate view of this Queue
where its elements are of type B,
given back and forth function from A
to B
.
Asynchronous queue interface. Operations are all nonblocking in their implementations, but may be 'semantically' blocking. For instance, a queue may have a bound on its size, in which case enqueuing may block until there is an offsetting dequeue.