Struct mioco::Mioco
[−]
[src]
pub struct Mioco { // some fields omitted }
Mioco instance.
Methods
impl Mioco
[src]
fn new() -> Self
Create new Mioco
instance.
fn new_configured(config: Config) -> Self
Create new Mioco
instance with custom configuration.
fn start<F, T>(&mut self, f: F) -> Result<T> where F: FnOnce() -> T, F: Send + 'static, T: Send + 'static
Start mioco instance.
Takes a starting handler function that will be executed in mioco
environment.
Will block until mioco
is finished - there are no more coroutines to run.
Returns the result of the f
.
See MiocoHandle::start()
.