pal_async::task

Trait Schedule

Source
pub trait Schedule: Send + Sync {
    // Required methods
    fn schedule(&self, runnable: Runnable);
    fn name(&self) -> Arc<str>;
}
Expand description

Trait for scheduling a task on an executor.

Required Methods§

Source

fn schedule(&self, runnable: Runnable)

Schedules a task to run.

Source

fn name(&self) -> Arc<str>

Gets the executor name.

Implementors§