pub trait Task<I, D>: Send + Sync {
// Required methods
fn id(&self) -> &I;
fn run(
&self,
input: Vec<Input<'_, I, D>>,
) -> impl Future<Output = Option<D>> + Send + Sync;
// Provided method
fn dependencies(&self) -> &[I] { ... }
}Required Methods§
fn id(&self) -> &I
fn run( &self, input: Vec<Input<'_, I, D>>, ) -> impl Future<Output = Option<D>> + Send + Sync
Provided Methods§
fn dependencies(&self) -> &[I]
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.