pub struct Waiter<T = ()> { /* private fields */ }Expand description
A task waiting for a Condition notification.
Implementations§
Source§impl<T> Waiter<T>
impl<T> Waiter<T>
Sourcepub async fn ready(&self) -> ConditionResult<T>
pub async fn ready(&self) -> ConditionResult<T>
Waits for the next condition result.
Sourcepub fn poll_ready(&self, cx: &mut Context<'_>) -> Poll<ConditionResult<T>>
pub fn poll_ready(&self, cx: &mut Context<'_>) -> Poll<ConditionResult<T>>
Polls for the next condition result.
The first poll registers this waiter. While the condition remains unlocked, later notifications wake the registered task.
Trait Implementations§
Auto Trait Implementations§
impl<T = ()> !RefUnwindSafe for Waiter<T>
impl<T = ()> !Send for Waiter<T>
impl<T = ()> !Sync for Waiter<T>
impl<T = ()> !UnwindSafe for Waiter<T>
impl<T> Freeze for Waiter<T>
impl<T> Unpin for Waiter<T>
impl<T> UnsafeUnpin for Waiter<T>
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§impl<F> IntoFuture for Fwhere
F: Future,
impl<F> IntoFuture for Fwhere
F: Future,
Source§type IntoFuture = F
type IntoFuture = F
Which kind of future are we turning this into?
Source§fn into_future(self) -> <F as IntoFuture>::IntoFuture
fn into_future(self) -> <F as IntoFuture>::IntoFuture
Creates a future from a value. Read more