pub trait EventContext<T> {
    // Required method
    fn on_event(&mut self, event: T);
}
Expand description

A context for emitting events.

EventContext encodes the common pattern for emitting atomic events of type T from core. An implementation of EventContext must guarantee that events are processed in the order they are emitted.

Required Methods§

source

fn on_event(&mut self, event: T)

Handles event.

Implementors§

source§

impl<E: Debug> EventContext<E> for FakeEventCtx<E>

source§

impl<Id, Event: Debug, State, FrameMeta> EventContext<Event> for FakeBindingsCtx<Id, Event, State, FrameMeta>