pub struct BrwLockPiWriteGuard<'a, Class: LockClass> { /* private fields */ }Expand description
A validation guard representing writer lock ownership and active list participation.
Implementations§
Source§impl<'a, Class: LockClass> BrwLockPiWriteGuard<'a, Class>
impl<'a, Class: LockClass> BrwLockPiWriteGuard<'a, Class>
Source§impl<'a, Class: LockClass> BrwLockPiWriteGuard<'a, Class>
impl<'a, Class: LockClass> BrwLockPiWriteGuard<'a, Class>
Sourcepub fn new(lock: &'a BrwLockPi<Class>) -> impl PinInit<Self, Infallible>
pub fn new(lock: &'a BrwLockPi<Class>) -> impl PinInit<Self, Infallible>
Creates a new stack-pinned validation guard initialization block.
Sourcepub fn token(&self) -> &LockToken<'a, Class>
pub fn token(&self) -> &LockToken<'a, Class>
Returns a shared reference to the lock proof LockToken.
Sourcepub fn token_mut(self: Pin<&mut Self>) -> &mut LockToken<'a, Class>
pub fn token_mut(self: Pin<&mut Self>) -> &mut LockToken<'a, Class>
Returns a mutable reference to the lock proof LockToken inside this pinned projection.
Sourcepub fn call_unlocked<R, F: FnOnce() -> R>(self: Pin<&mut Self>, f: F) -> R
pub fn call_unlocked<R, F: FnOnce() -> R>(self: Pin<&mut Self>, f: F) -> R
Temporarily releases the write lock before executing the given callable f and then
re-acquires the write lock.
Trait Implementations§
Source§impl<'a, Class: LockClass> Drop for BrwLockPiWriteGuard<'a, Class>
impl<'a, Class: LockClass> Drop for BrwLockPiWriteGuard<'a, Class>
Source§impl<'a, Class: LockClass> HasPinData for BrwLockPiWriteGuard<'a, Class>
impl<'a, Class: LockClass> HasPinData for BrwLockPiWriteGuard<'a, Class>
Source§impl<'a, Class: LockClass> PinnedDrop for BrwLockPiWriteGuard<'a, Class>
impl<'a, Class: LockClass> PinnedDrop for BrwLockPiWriteGuard<'a, Class>
Auto Trait Implementations§
impl<'a, Class> !Freeze for BrwLockPiWriteGuard<'a, Class>
impl<'a, Class> !RefUnwindSafe for BrwLockPiWriteGuard<'a, Class>
impl<'a, Class> !Send for BrwLockPiWriteGuard<'a, Class>
impl<'a, Class> !Sync for BrwLockPiWriteGuard<'a, Class>
impl<'a, Class> !UnwindSafe for BrwLockPiWriteGuard<'a, Class>
impl<'a, Class> UnsafeUnpin for BrwLockPiWriteGuard<'a, Class>
Blanket Implementations§
§impl<T> Any for Twhere
T: 'static + ?Sized,
impl<T> Any for Twhere
T: 'static + ?Sized,
§impl<T> Borrow<T> for Twhere
T: ?Sized,
impl<T> Borrow<T> for Twhere
T: ?Sized,
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T, U> Into<U> for Twhere
U: From<T>,
impl<T, U> Into<U> for Twhere
U: From<T>,
Source§impl<T> PinInit<T> for T
impl<T> PinInit<T> for T
Source§unsafe fn __pinned_init(self, slot: *mut T) -> Result<(), !>
unsafe fn __pinned_init(self, slot: *mut T) -> Result<(), !>
Initializes
slot. Read moreSource§fn pin_chain<F>(self, f: F) -> ChainPinInit<Self, F, T, E>where
F: FnOnce(Pin<&mut T>) -> Result<(), E>,
fn pin_chain<F>(self, f: F) -> ChainPinInit<Self, F, T, E>where
F: FnOnce(Pin<&mut T>) -> Result<(), E>,
First initializes the value using
self then calls the function f with the initialized
value. Read more