Trait lock_order::lock::ExclusiveLock

source ·
pub trait ExclusiveLock<T>: 'static {
    type Guard<'l>: DerefMut<Target = T>;

    // Required method
    fn lock(&self) -> Self::Guard<'_>;
}
Expand description

Abstracts an exclusive lock (i.e. a Mutex).

Required Associated Types§

source

type Guard<'l>: DerefMut<Target = T>

The guard type returned when locking the lock.

Required Methods§

source

fn lock(&self) -> Self::Guard<'_>

Locks this lock.

Object Safety§

This trait is not object safe.

Implementors§