/// Dispatch pending events to their callbacks
///
/// If some sources have events available, their callbacks will be immediatly called.
/// Otherwise this will wait until an event is receive or the provided `timeout`
/// is reached. If `timeout` is `None`, it will wait without a duration limit.
///
/// Once pending events have been processed or the timeout is reached, all pending
/// idle callbacks will be fired before this method returns.
Dispatch pending events to their callbacks
If some sources have events available, their callbacks will be immediatly called.
Otherwise this will wait until an event is receive or the provided `timeout`
is reached. If `timeout` is `None`, it will wait without a duration limit.

Once pending events have been processed or the timeout is reached, all pending
idle callbacks will be fired before this method returns.
Dispatch pending events to their callbacks If some sources have events available their callbacks will be immediatly called . Otherwise this will wait until an event is receive or the provided ` timeout ` is reached . If ` timeout ` is ` None ` it will wait without a duration limit . Once pending events have been processed or the timeout is reached all pending idle callbacks will be fired before this method returns .
pub fn dispatch<D: Into<Option<Duration>>>(
        &mut self,
        timeout: D,
        data: &mut Data,
    ) -> io::Result<()> {
        self.dispatch_events(timeout.into(), data)?;
        self.dispatch_idles(data);
        Ok(())
    }
pub fn dispatch < D : Into < Option < Duration > > > ( & mut self , timeout : D , data : & mut Data , ) -> io :: Result < ( ) > { self . dispatch_events ( timeout . into ( ) , data ) ? ; self . dispatch_idles ( data ) ; Ok ( ( ) ) }
Dispatch pending events to their callbacks
If some sources have events available, their callbacks will be immediatly called.
Dispatch pending events to their callbacks If some sources have events available their callbacks will be immediatly called .
&mut self
timeout
D
data
&mut Data