Struct Mutex
pub struct Mutex { pub(in ::sys::sync::mutex::futex) futex: Atomic<u32> }
Fields
futex: Atomic<u32>
Implementations
impl Mutex
const fn new() -> Selffn try_lock(&self) -> boolfn lock(&self)fn lock_contended(&self)fn spin(&self) -> u32unsafe fn unlock(&self)fn wake(&self)
Auto Trait Implementations
impl !Freeze for Mutex
impl RefUnwindSafe for Mutex
impl Send for Mutex
impl Sync for Mutex
impl Unpin for Mutex
impl UnsafeUnpin for Mutex
impl UnwindSafe for Mutex
Blanket Implementations
impl<T> Any for Mutex
where
T: 'static + ?Sized,
fn type_id(&self) -> TypeId
impl<T> Borrow<T> for Mutex
where
T: ?Sized,
fn borrow(&self) -> &T
impl<T> BorrowMut<T> for Mutex
where
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
impl<T> From<T> for Mutex
fn from(t: T) -> TReturns the argument unchanged.
impl<T> SizeHint for Mutex
where
T: ?Sized,
fn lower_bound(&self) -> usizefn upper_bound(&self) -> Option<usize>
impl<T> SizedTypeProperties for Mutex
impl<T, U> Into<U> for Mutex
where
U: From<T>,
fn into(self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom<U> for Mutex
where
U: Into<T>,
type Error = Infallible;fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
impl<T, U> TryInto<U> for Mutex
where
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error;fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>