Struct evdi::events::HandleEvents
source · pub struct HandleEvents { /* private fields */ }
Implementations§
source§impl HandleEvents
impl HandleEvents
sourcepub fn current_mode(&self) -> Option<Mode>
pub fn current_mode(&self) -> Option<Mode>
The most recent mode received, if a mode has been received.
sourcepub async fn await_mode(
&self,
timeout: Duration
) -> Result<Mode, AwaitEventError>
pub async fn await_mode( &self, timeout: Duration ) -> Result<Mode, AwaitEventError>
If a mode event has been received, return it. Otherwise wait for a mode event.