Struct syncbox::DelayQueue [] [src]

pub struct DelayQueue<T: Delayed + Send> { /* fields omitted */ }

An unbounded blocking queue of delayed values. When a value is pushed onto the queue, a delay is included. The value will only be able to be popped off once the specified delay has expired. The head of the queue is the value whose delay is expired and furthest in the past.

Methods

impl<T: Delayed + Send> DelayQueue<T>
[src]

Create a new DelayQueue

Retrieves and removes the head of the queue, blocking if necessary for up to timeout.

Trait Implementations

impl<T: Delayed + Send> Queue<T> for DelayQueue<T>
[src]

Retrieves and removes the head of this queue or returns None if the queue is empty. Read more

Returns true if the underlying data structure does not contain any elements. Read more

impl<T: Delayed + Send> SyncQueue<T> for DelayQueue<T>
[src]

Retrieves and removes the head of this queue, waiting if necessary until an element becomes available. Read more

impl<T: Delayed + Send> Clone for DelayQueue<T>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more