pub struct RwLockReadGuard<'lock, T: ?Sized> { /* private fields */ }
Expand description
RAII structure used to release the shared read access of a RwLock
when
dropped.
The data protected by the RwLock
can be accessed through this guard via
its Deref
implementation.
This guard can be held across any .await
point, as it implements
Send
.
This structure is created by the read
and try_read
methods on
RwLock
.
Trait Implementations§
Source§impl<T: ?Sized> Deref for RwLockReadGuard<'_, T>
impl<T: ?Sized> Deref for RwLockReadGuard<'_, T>
impl<T> Send for RwLockReadGuard<'_, T>
impl<T> Sync for RwLockReadGuard<'_, T>
Auto Trait Implementations§
impl<'lock, T> Freeze for RwLockReadGuard<'lock, T>where
T: ?Sized,
impl<'lock, T> !RefUnwindSafe for RwLockReadGuard<'lock, T>
impl<'lock, T> Unpin for RwLockReadGuard<'lock, T>where
T: ?Sized,
impl<'lock, T> !UnwindSafe for RwLockReadGuard<'lock, T>
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