#[repr(C)]pub enum ThreadSync {
Sleep(ThreadSyncSleep, ThreadSyncResult),
Wake(ThreadSyncWake, ThreadSyncResult),
}
Expand description
Either a sleep or wake request. The syscall comprises of a number of either sleep or wake requests.
Variants§
Sleep(ThreadSyncSleep, ThreadSyncResult)
Wake(ThreadSyncWake, ThreadSyncResult)
Implementations§
source§impl ThreadSync
impl ThreadSync
sourcepub fn new_sleep(sleep: ThreadSyncSleep) -> Self
pub fn new_sleep(sleep: ThreadSyncSleep) -> Self
Build a sleep request.
sourcepub fn new_wake(wake: ThreadSyncWake) -> Self
pub fn new_wake(wake: ThreadSyncWake) -> Self
Build a wake request.
sourcepub fn get_result(&self) -> ThreadSyncResult
pub fn get_result(&self) -> ThreadSyncResult
Get the result of the thread sync operation.
pub fn ready(&self) -> bool
Trait Implementations§
source§impl Clone for ThreadSync
impl Clone for ThreadSync
source§fn clone(&self) -> ThreadSync
fn clone(&self) -> ThreadSync
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for ThreadSync
impl Debug for ThreadSync
source§impl Ord for ThreadSync
impl Ord for ThreadSync
source§fn cmp(&self, other: &ThreadSync) -> Ordering
fn cmp(&self, other: &ThreadSync) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for ThreadSync
impl PartialEq for ThreadSync
source§impl PartialOrd for ThreadSync
impl PartialOrd for ThreadSync
impl Copy for ThreadSync
impl Eq for ThreadSync
impl StructuralPartialEq for ThreadSync
Auto Trait Implementations§
impl Freeze for ThreadSync
impl !ObjSafe for ThreadSync
impl RefUnwindSafe for ThreadSync
impl Send for ThreadSync
impl !Sync for ThreadSync
impl Unpin for ThreadSync
impl UnwindSafe for ThreadSync
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.