Trait rsevents::Awaitable[][src]

pub trait Awaitable {
    fn wait(&self);
fn wait_for(&self, limit: Duration) -> bool;
fn wait0(&self) -> bool; }

Required Methods

Check if the event has been signalled, and if not, block waiting for it to be set.

Check if the event has been signalled, and if not, block for limit waiting for it to be set. Returns true if the event was originally set or if it was signalled within the specified duration, and false otherwise (if the timeout elapsed without the event becoming set).

Test if an event is available without blocking, return false immediately if it is not set. Note that this is not the same as calling Awaitable::wait_for() with a Duration of zero, as the calling thread never yields.

Implementors