fire method
Fire a event
Implementation
@override
void fire(AppEvent event) {
if (_history.length >= maxHistoryLength) {
_history.removeAt(0);
}
_history.add(EventBusHistoryEntry(event, event.timestamp));
// 1. Fire the event
_lastEventSubject.add(event);
// 2. Map if needed
_map(event);
// 3. Reset stream
_lastEventSubject.add(EmptyEvent());
if (allowLogging) {
_logger.d(' ⚡️ [${event.timestamp}] $event');
}
}