pub trait WakeableChannel {
// Required methods
fn set_waker(&mut self, waker: Box<dyn EventLoopWaker>);
fn clear_waker(&mut self);
fn waker(&self) -> Option<&dyn EventLoopWaker>;
}Expand description
A channel that can wake an event loop when messages arrive.
Required Methods§
Sourcefn set_waker(&mut self, waker: Box<dyn EventLoopWaker>)
fn set_waker(&mut self, waker: Box<dyn EventLoopWaker>)
Set the event loop waker.
When messages arrive on this channel, the waker will be called to notify the event loop.
Sourcefn clear_waker(&mut self)
fn clear_waker(&mut self)
Remove the waker.
Sourcefn waker(&self) -> Option<&dyn EventLoopWaker>
fn waker(&self) -> Option<&dyn EventLoopWaker>
Get a reference to the current waker, if any.