Trait lightning::events::EventHandler
source · pub trait EventHandler {
// Required method
fn handle_event(&self, event: Event);
}Expand description
A trait implemented for objects handling events from EventsProvider.
An async variation also exists for implementations of EventsProvider that support async
event handling. The async event handler should satisfy the generic bounds: F: core::future::Future, H: Fn(Event) -> F.
Required Methods§
sourcefn handle_event(&self, event: Event)
fn handle_event(&self, event: Event)
Handles the given Event.
See EventsProvider for details that must be considered when implementing this method.