pub trait Service: Send + Sync {
// Required method
fn serve<'life0, 'async_trait>(
&'life0 self,
context: BotContext,
event: BotEvent,
) -> Pin<Box<dyn Future<Output = HandlerControl> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Required Methods§
Sourcefn serve<'life0, 'async_trait>(
&'life0 self,
context: BotContext,
event: BotEvent,
) -> Pin<Box<dyn Future<Output = HandlerControl> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn serve<'life0, 'async_trait>(
&'life0 self,
context: BotContext,
event: BotEvent,
) -> Pin<Box<dyn Future<Output = HandlerControl> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Extractors are not possible to be used in services but you can call FromEvent::from_event manually.