Trait songbird::events::EventHandler[][src]

pub trait EventHandler: Send + Sync {
    fn act<'life0, 'life1, 'life2, 'async_trait>(
        &'life0 self,
        ctx: &'life1 EventContext<'life2>
    ) -> Pin<Box<dyn Future<Output = Option<Event>> + Send + 'async_trait>>
    where
        'life0: 'async_trait,
        'life1: 'async_trait,
        'life2: 'async_trait,
        Self: 'async_trait
; }
Expand description

Trait to handle an event which can be fired per-track, or globally.

These may be feasibly reused between several event sources.

Required methods

Respond to one received event.

Implementors