Struct Pollable
pub struct Pollable { /* private fields */ }Expand description
pollable represents a single I/O event which may be ready, or not.
The host representation of the wasi:io/poll.pollable resource.
A pollable is not the same thing as a Rust Future: the same pollable may be used to
repeatedly check for readiness of a given condition, e.g. if a stream is readable
or writable. So, rather than containing a Future, which can only become Ready once, a
DynPollable contains a way to create a Future in each call to poll.
Implementations§
§impl DynPollable
impl DynPollable
pub fn type_name(&self) -> &'static str
pub fn type_name(&self) -> &'static str
The name of the concrete type this pollable is subscribed to, as
reported by Pollable::type_name when it was created by
subscribe.
This is intended for debugging purposes only.
Trait Implementations§
Auto Trait Implementations§
impl Forget for DynPollable
impl Freeze for DynPollable
impl Move for DynPollable
impl RefUnwindSafe for DynPollable
impl Send for DynPollable
impl Sync for DynPollable
impl Unpin for DynPollable
impl UnsafeUnpin for DynPollable
impl UnwindSafe for DynPollable
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
impl<T> ErasedDestructor for Twhere
T: 'static,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more