Trait lock_api::RawMutexTimed[][src]

pub unsafe trait RawMutexTimed: RawMutex {
    type Duration;
    type Instant;
    fn try_lock_for(&self, timeout: Self::Duration) -> bool;
fn try_lock_until(&self, timeout: Self::Instant) -> bool; }
Expand description

Additional methods for mutexes which support locking with timeouts.

The Duration and Instant types are specified as associated types so that this trait is usable even in no_std environments.

Associated Types

Duration type used for try_lock_for.

Instant type used for try_lock_until.

Required methods

Attempts to acquire this lock until a timeout is reached.

Attempts to acquire this lock until a timeout is reached.

Implementors