Spawner

Type Alias Spawner 

Source
pub type Spawner = Box<dyn Fn(Pin<Box<dyn Future<Output = ()> + Send>>) + Send + Sync>;
Expand description

A spawner function that executes futures on an async runtime.

This abstraction allows you to use whatever concurrency model you want (tokio, async-std, embassy, etc.).

Aliased Typeยง

pub struct Spawner(/* private fields */);