pub struct ReferenceCountedMutex { /* private fields */ }
Expand description
Struct that holds the mutex used for synchronisation and manages removing itself from the containing map once no longer referenced by any threads. Removes itself from the map when decrementing the counter from 1 to 0 and makes sure that the counter cannot be incremented back up once reaching 0 in case a thread finds a ReferenceCountedMutex that is in the process of being removed from the map.
Auto Trait Implementations§
impl !Freeze for ReferenceCountedMutex
impl !RefUnwindSafe for ReferenceCountedMutex
impl Send for ReferenceCountedMutex
impl Sync for ReferenceCountedMutex
impl Unpin for ReferenceCountedMutex
impl UnwindSafe for ReferenceCountedMutex
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