[−]Trait esp32_hal::prelude::Mutex
Any object implementing this trait guarantees exclusive access to the data contained within the mutex for the duration of the lock.
Associated Types
type Data
Data protected by the mutex.
Required methods
fn lock<R>(&mut self, f: impl FnOnce(&mut Self::Data) -> R) -> R
Creates a critical section and grants temporary access to the protected data.
Implementations on Foreign Types
impl<'_, T> Mutex for &'_ SpinLockMutex<T>
[src]
type Data = T
fn lock<R>(
&mut self,
f: impl FnOnce(&mut <&'_ SpinLockMutex<T> as Mutex>::Data) -> R
) -> R
[src]
&mut self,
f: impl FnOnce(&mut <&'_ SpinLockMutex<T> as Mutex>::Data) -> R
) -> R
impl<'_, T> Mutex for &'_ CriticalSectionMutex<T>
[src]
type Data = T
fn lock<R>(
&mut self,
f: impl FnOnce(&mut <&'_ CriticalSectionMutex<T> as Mutex>::Data) -> R
) -> R
[src]
&mut self,
f: impl FnOnce(&mut <&'_ CriticalSectionMutex<T> as Mutex>::Data) -> R
) -> R
impl<'a, T> Mutex for Exclusive<'a, T>
impl<'_, T> Mutex for &'_ RefCell<T>
Loading content...Implementors
impl<'_, L> Mutex for &'_ mut L where
L: Mutex,
L: Mutex,