Trait telecomande::Manager
source · [−]pub trait Manager: Send + Sync + 'static {
type Signal: Signal;
fn handle<'life0, 'async_trait>(
&'life0 mut self,
signal: Self::Signal
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>
where
'life0: 'async_trait,
Self: 'async_trait;
}
Expand description
Represents the handling of crate::traits::Signal
in a task.
consumed by the crate::utils::spawn
function.
Required Associated Types
Required Methods
Method called on each received crate::traits::Signal
.
Values may be returned through the use of tokio::sync::oneshot
channels.
May need the #[telecomande::async_trait]
macro over the implementation block in order to satisfy the compiler.