WorkQueue.push

QueueStatus push(WorkItem item) @trusted

Push a work item onto the queue, blocking if full.

For unbounded queues, this never blocks due to capacity.

Parameters

itemThe work item to push.

Returns

QueueStatus.SUCCESS if the item was pushed,

QueueStatus.CLOSED if the queue has been closed.

QueueStatus push(void delegate() @safe task, string name = null) @trusted

ditto