Struct BlockingQueue
Reactor aware fixed size queue.
struct BlockingQueue(Type, ushort MaxItems)
;
Unlike mecca.container.queue, this queue does not assert when an operation cannot be fulfilled. Instead, it blocks the calling fiber
until the operation can be completed.
Properties
Name | Type | Description |
empty [get]
|
bool | Returns true if no items are currenlty queued.
|
full [get]
|
bool | Returns true if trying to add a new item would block.
|
Methods
Name | Description |
pop
|
Pop a single element from the queue
|
push
|
Add an item to the queue.
|
push
|
Pushes an uninitialized item to the queue.
|
pushWaitersQueueWaitForHead
|
Wait until all current fibers waiting to push have done so.
|
Parameters
Name | Description |
Type | the item type to be used. |
MaxItems | the queue's capacity. |