[−][src]Struct async_io::parking::Parker
Parks a thread.
Implementations
impl Parker
[src]
pub fn new() -> Parker
[src]
Creates a new Parker
.
pub fn park(&self)
[src]
Blocks the current thread until the token is made available.
pub fn park_timeout(&self, timeout: Duration) -> bool
[src]
Blocks the current thread until the token is made available or the timeout is reached.
pub fn park_deadline(&self, deadline: Instant) -> bool
[src]
Blocks the current thread until the token is made available or the deadline is reached.
pub fn unpark(&self)
[src]
Atomically makes the token available if it is not already.
pub fn unparker(&self) -> Unparker
[src]
Returns a handle for unparking.
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Parker
impl Send for Parker
impl Sync for Parker
impl Unpin for Parker
impl !UnwindSafe for Parker
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,