Struct qutex::qutex::Qutex [] [src]

pub struct Qutex<T> { /* fields omitted */ }

A queue-backed exclusive data lock.

Methods

impl<T> Qutex<T>
[src]

Creates and returns a new Qutex.

Returns a new FutureGuard which can be used as a future and will resolve into a Guard.

Pushes a lock request onto the queue.

Returns a mutable reference to the inner Vec if there are currently no other copies of this Qutex.

Since this call borrows the inner lock mutably, no actual locking needs to take place---the mutable borrow statically guarantees no locks exist.

Returns a reference to the inner value.

This is frought with potential peril.

Returns a mutable reference to the inner value.

Drinking water from the tap in 1850's London would be safer.

Pops the next lock request in the queue if this lock is unlocked.

Unlocks this lock and wakes up the next task in the queue.

Trait Implementations

impl<T> From<T> for Qutex<T>
[src]

Performs the conversion.

impl<T> Clone for Qutex<T>
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more