use std::fmt::Debug;
pub trait Job: Debug + Send + Sync + 'static {
type Output: Clone + Send + Sync + 'static;
type Error: Send + Sync + 'static;
fn execute(&mut self) -> Result<Self::Output, Self::Error>;
}
pub trait Keyed<Key>: Job
where
Key: Clone + std::hash::Hash + Eq + Send + Sync + Debug + 'static,
{
fn key(&self) -> Key;
}
pub trait Executable: Send + Sync + Debug {
fn execute(&mut self);
}