[−][src]Trait fibers::Executor
The Executor
trait allows for spawning and executing fibers.
Associated Types
Loading content...Required methods
fn handle(&self) -> Self::Handle
Returns the handle of the executor.
fn run_once(&mut self) -> Result<()>
Runs one one unit of works.
Provided methods
fn run_fiber<T, E>(
&mut self,
monitor: Monitor<T, E>
) -> Result<Result<T, MonitorError<E>>>
&mut self,
monitor: Monitor<T, E>
) -> Result<Result<T, MonitorError<E>>>
Runs until the monitored fiber exits.
fn run_future<F: Future>(
&mut self,
future: F
) -> Result<Result<F::Item, F::Error>>
&mut self,
future: F
) -> Result<Result<F::Item, F::Error>>
Runs until the future is ready.
fn run(self) -> Result<()>
Runs infinitely until an error happens.