pub struct RwSpinlock { /* private fields */ }Expand description
A spinlock-based RawRwLock implementation.
This type implements the blocking::RawRwLock trait. This allows it to be
used with the blocking::RwLock type when a spinlock-based reader-writer
lock is needed.
Trait Implementations§
Source§impl ConstInit for RwSpinlock
 
impl ConstInit for RwSpinlock
Source§const INIT: RwSpinlock
 
const INIT: RwSpinlock
Create a new instance. Read more
Source§impl Debug for RwSpinlock
 
impl Debug for RwSpinlock
Source§impl RawRwLock for RwSpinlock
 
impl RawRwLock for RwSpinlock
Source§type GuardMarker = ()
 
type GuardMarker = ()
Marker type which determines whether a lock guard should be 
Send.Acquires a shared lock, blocking the current thread/CPU core until it is
able to do so.
Attempts to acquire a shared lock without blocking.
Releases a shared lock. Read more
Source§fn lock_exclusive(&self)
 
fn lock_exclusive(&self)
Acquires an exclusive lock, blocking the current thread/CPU core until
it is able to do so.
Source§fn try_lock_exclusive(&self) -> bool
 
fn try_lock_exclusive(&self) -> bool
Attempts to acquire an exclusive lock without blocking.
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
Returns 
true if this RwLock is currently locked exclusively.Auto Trait Implementations§
impl !Freeze for RwSpinlock
impl RefUnwindSafe for RwSpinlock
impl Send for RwSpinlock
impl Sync for RwSpinlock
impl Unpin for RwSpinlock
impl UnwindSafe for RwSpinlock
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