pub trait Spawn<T: Future<Item = (), Error = ()>> {
// Required method
fn spawn_detached(&self, f: T);
}Expand description
Value that can spawn a future
On spawn, the executor takes ownership of the future and becomes responsible
to call Future::poll() whenever a readiness notification is raised.
Required Methods§
Sourcefn spawn_detached(&self, f: T)
fn spawn_detached(&self, f: T)
Spawns a future to run on this Spawn.
This function will return immediately, and schedule the future f to
run on self. The details of scheduling and execution are left to the
implementations of Spawn.