Trait sp_core::traits::SpawnNamed
source · pub trait SpawnNamed: DynClone + Send + Sync {
// Required methods
fn spawn_blocking(
&self,
name: &'static str,
group: Option<&'static str>,
future: BoxFuture<'static, ()>,
);
fn spawn(
&self,
name: &'static str,
group: Option<&'static str>,
future: BoxFuture<'static, ()>,
);
}
Expand description
Something that can spawn tasks (blocking and non-blocking) with an assigned name and optional group.