Handler<T> typedef
Handler function type for processing events. The handler receives the event data and the previous data from the same topic (the value that was stored in EventNode.lastData before this event). If the handler completes but doesn't call EventDTO.completer, EventNode returns null (EventDTO.completer(null)) to the sender. If the handler throws, the sender receives the error through the completer.
Implementation
typedef Handler<T> = Future<void> Function(EventDTO<T> dto, T? lastData);