Struct triggered::Listener [−][src]
pub struct Listener { /* fields omitted */ }
Expand description
A struct used to wait for a trigger event from a Trigger
.
Can be waited on synchronously via Listener::wait
or asynchronously thanks to the struct
implementing Future
.
The listener can be cloned and any amount of threads and tasks can wait for the same trigger at the same time.
Implementations
Wait for this trigger synchronously.
Blocks the current thread until the corresponding Trigger
is triggered.
If the trigger has already been triggered at least once, this returns immediately.
Returns true if this trigger has been triggered.
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Listener
impl !UnwindSafe for Listener
Blanket Implementations
Mutably borrows from an owned value. Read more
🔬 This is a nightly-only experimental API. (
into_future
)The output that the future will produce on completion.
type Future = F
type Future = F
🔬 This is a nightly-only experimental API. (
into_future
)Which kind of future are we turning this into?
🔬 This is a nightly-only experimental API. (
into_future
)Creates a future from a value.