Struct maitake::sync::rwlock::RwLockWriteGuard
pub struct RwLockWriteGuard<'lock, T, Lock = Spinlock>{ /* private fields */ }
Expand description
RAII structure used to release the exclusive write access of a RwLock
when
dropped.
The data protected by the RwLock
can be accessed through this guard via
its Deref
and DerefMut
implementations.
This guard can be held across any .await
point, as it implements
Send
.
This structure is created by the write
and try_write
methods on
RwLock
.
Trait Implementations§
§impl<T> Debug for RwLockWriteGuard<'_, T>
impl<T> Debug for RwLockWriteGuard<'_, T>
§impl<T, Lock> Deref for RwLockWriteGuard<'_, T, Lock>
impl<T, Lock> Deref for RwLockWriteGuard<'_, T, Lock>
§impl<T> DerefMut for RwLockWriteGuard<'_, T>where
T: ?Sized,
impl<T> DerefMut for RwLockWriteGuard<'_, T>where
T: ?Sized,
§fn deref_mut(&mut self) -> &mut <RwLockWriteGuard<'_, T> as Deref>::Target
fn deref_mut(&mut self) -> &mut <RwLockWriteGuard<'_, T> as Deref>::Target
Mutably dereferences the value.
impl<T> Send for RwLockWriteGuard<'_, T>
impl<T> Sync for RwLockWriteGuard<'_, T>
Auto Trait Implementations§
impl<'lock, T, Lock = Spinlock> !RefUnwindSafe for RwLockWriteGuard<'lock, T, Lock>
impl<'lock, T, Lock = Spinlock> !Send for RwLockWriteGuard<'lock, T, Lock>
impl<'lock, T, Lock = Spinlock> !Sync for RwLockWriteGuard<'lock, T, Lock>
impl<'lock, T: ?Sized, Lock> Unpin for RwLockWriteGuard<'lock, T, Lock>
impl<'lock, T, Lock = Spinlock> !UnwindSafe for RwLockWriteGuard<'lock, T, Lock>
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more