Trait bevy_defer::AsyncCommandsExtension

source ·
pub trait AsyncCommandsExtension {
    // Required method
    fn spawn_task<F: Future<Output = AccessResult> + 'static>(
        &mut self,
        f: impl FnOnce() -> F + Send + 'static
    ) -> &mut Self;
}
Expand description

Extension for Commands.

Required Methods§

source

fn spawn_task<F: Future<Output = AccessResult> + 'static>( &mut self, f: impl FnOnce() -> F + Send + 'static ) -> &mut Self

Spawn a task to be run on the AsyncExecutor.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl AsyncCommandsExtension for Commands<'_, '_>

source§

fn spawn_task<F: Future<Output = AccessResult> + 'static>( &mut self, f: impl FnOnce() -> F + Send + 'static ) -> &mut Self

Implementors§