public void ConsumeEvent(Event @event)
 {
     foreach (IEventHandler handler in eventHandlerProvider.GetEventHandlers(@event.GetType()))
     {
         handler.When(@event);
     }
 }
Esempio n. 2
0
 private void DispatchEvent(Event @event)
 {
     foreach (var handler in EventRoutes.Where(x => x.HandlerType == @event.GetType()))
     {
         handler.Handle(@event);
     }
 }