pub struct RawRwSpinlock(/* private fields */);๐Deprecated since 0.2.4: Use spin-rs instead
Expand description
Raw spinlock rwlock, wrapped in the lock_api RwLock struct.
Trait Implementationsยง
Sourceยงimpl RawRwLock for RawRwSpinlock
impl RawRwLock for RawRwSpinlock
Sourceยงconst INIT: RawRwSpinlock
const INIT: RawRwSpinlock
Initial value for an unlocked
RwLock.Sourceยงtype GuardMarker = GuardSend
type GuardMarker = GuardSend
Marker type which determines whether a lock guard should be
Send. Use
one of the GuardSend or GuardNoSend helper types here.Acquires a shared lock, blocking the current thread until it is able to do so.
Attempts to acquire a shared lock without blocking.
Sourceยงfn try_lock_exclusive(&self) -> bool
fn try_lock_exclusive(&self) -> bool
Attempts to acquire an exclusive lock without blocking.
Sourceยงfn lock_exclusive(&self)
fn lock_exclusive(&self)
Acquires an exclusive lock, blocking the current thread until it is able to do so.
Releases a shared lock. Read more
Sourceยงunsafe fn unlock_exclusive(&self)
unsafe fn unlock_exclusive(&self)
Releases an exclusive lock. Read more
Sourceยงfn is_locked_exclusive(&self) -> bool
fn is_locked_exclusive(&self) -> bool
Check if this
RwLock is currently exclusively locked.Sourceยงimpl RawRwLockDowngrade for RawRwSpinlock
impl RawRwLockDowngrade for RawRwSpinlock
Sourceยงimpl RawRwLockUpgrade for RawRwSpinlock
impl RawRwLockUpgrade for RawRwSpinlock
Sourceยงfn lock_upgradable(&self)
fn lock_upgradable(&self)
Acquires an upgradable lock, blocking the current thread until it is able to do so.
Sourceยงfn try_lock_upgradable(&self) -> bool
fn try_lock_upgradable(&self) -> bool
Attempts to acquire an upgradable lock without blocking.
Sourceยงunsafe fn try_upgrade(&self) -> bool
unsafe fn try_upgrade(&self) -> bool
Attempts to upgrade an upgradable lock to an exclusive lock without
blocking. Read more
Sourceยงunsafe fn unlock_upgradable(&self)
unsafe fn unlock_upgradable(&self)
Releases an upgradable lock. Read more
Auto Trait Implementationsยง
impl !Freeze for RawRwSpinlock
impl RefUnwindSafe for RawRwSpinlock
impl Send for RawRwSpinlock
impl Sync for RawRwSpinlock
impl Unpin for RawRwSpinlock
impl UnwindSafe for RawRwSpinlock
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