pub trait EventHandler<E> { type Output; type Error; // Required method fn handle(&self, event: E) -> Result<Self::Output, Self::Error>; }