pub struct UpdateGuard<'a, T: 'a> { /* private fields */ }
Expand description
A RAII guard providing mutable access to the inactive value of a PairLock
,
The values becomes active when the guard is dropped.
Implementations§
Source§impl<'a, T> UpdateGuard<'a, T>
impl<'a, T> UpdateGuard<'a, T>
Sourcepub fn active(this: &Self) -> &T
pub fn active(this: &Self) -> &T
Returns a shared reference to the active value of the PairLock
.
It can not be mutate it while the PairLock
is locked, and is therefore
safe to read.
Trait Implementations§
Source§impl<'a, T: Debug> Debug for UpdateGuard<'a, T>
impl<'a, T: Debug> Debug for UpdateGuard<'a, T>
Source§impl<'a, T> Deref for UpdateGuard<'a, T>
impl<'a, T> Deref for UpdateGuard<'a, T>
Source§impl<'a, T> DerefMut for UpdateGuard<'a, T>
impl<'a, T> DerefMut for UpdateGuard<'a, T>
Source§impl<'a, T> Drop for UpdateGuard<'a, T>
impl<'a, T> Drop for UpdateGuard<'a, T>
Auto Trait Implementations§
impl<'a, T> Freeze for UpdateGuard<'a, T>
impl<'a, T> !RefUnwindSafe for UpdateGuard<'a, T>
impl<'a, T> !Send for UpdateGuard<'a, T>
impl<'a, T> Sync for UpdateGuard<'a, T>
impl<'a, T> Unpin for UpdateGuard<'a, T>
impl<'a, T> !UnwindSafe for UpdateGuard<'a, 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