Trait concurrency_traits::Mutex[][src]

pub trait Mutex<'a>: TryMutex<'a> {
    fn lock(&'a self) -> Self::Guard;
}

A Generic Mutex trait

Implementation

It is recommended to implement MutexSized if the implement-ee can be sized.

Required methods

fn lock(&'a self) -> Self::Guard[src]

Locks the mutex, blocking until successful

Loading content...

Implementations on Foreign Types

impl<'a, T: ?Sized> Mutex<'a> for Mutex<T> where
    T: 'a, 
[src]

impl<'__a, 'a, T: ?Sized> Mutex<'__a> for &'a T where
    T: Mutex<'__a>, 
[src]

impl<'__a, 'a, T: ?Sized> Mutex<'__a> for &'a mut T where
    T: Mutex<'__a>, 
[src]

impl<'__a, T: ?Sized> Mutex<'__a> for ManuallyDrop<T> where
    T: Mutex<'__a>, 
[src]

impl<'__a, T> Mutex<'__a> for AssertUnwindSafe<T> where
    T: Mutex<'__a>, 
[src]

impl<'__a, T: ?Sized> Mutex<'__a> for Rc<T> where
    T: Mutex<'__a>, 
[src]

impl<'__a, T: ?Sized> Mutex<'__a> for Arc<T> where
    T: Mutex<'__a>, 
[src]

impl<'__a, T: ?Sized> Mutex<'__a> for Box<T> where
    T: Mutex<'__a>, 
[src]

impl<'__a, 'a, T> Mutex<'__a> for Cow<'a, T> where
    T: Mutex<'__a> + Clone
[src]

impl<'a, T> Mutex<'a> for Pin<T> where
    T: Deref,
    T::Target: Mutex<'a>, 
[src]

Loading content...

Implementors

impl<'a, T, M> Mutex<'a> for CustomMutex<T, M> where
    T: 'a,
    M: RawMutex + 'a, 
[src]

Loading content...