pub trait Runnable: Send + 'static {
type Output: Send + 'static;
// Required method
fn run(self) -> Self::Output;
}Expand description
A trait for defining a task that can be executed, typically in a separate thread.
Types implementing Runnable must be Send and 'static to ensure they
can be safely transferred across thread boundaries.