[][src]Trait async_executors::SpawnHandleExt

pub trait SpawnHandleExt<Out: 'static + Send>: SpawnHandle<Out> {
    fn spawn_handle(
        &self,
        future: impl Future<Output = Out> + Send + 'static
    ) -> Result<JoinHandle<Out>, SpawnError>; }
This is supported on feature="spawn_handle" only.

Convenience trait for passing in a generic future to SpawnHandle. Much akin to Spawn and SpawnExt in the futures library.

Required methods

fn spawn_handle(
    &self,
    future: impl Future<Output = Out> + Send + 'static
) -> Result<JoinHandle<Out>, SpawnError>

This is supported on feature="spawn_handle" only.

Spawn a future and return a JoinHandle that can be awaited for the output of the future.

Loading content...

Implementors

impl<T: ?Sized, Out> SpawnHandleExt<Out> for T where
    T: SpawnHandle<Out>,
    Out: 'static + Send
[src]

Loading content...