Ejemplo n.º 1
0
        public void Publish <TNotification>(TNotification notification) where TNotification : INotification
        {
            var handlers = _handlerFactory.CreateAll <INotificationHandler <TNotification> >();

            foreach (var handler in handlers)
            {
                handler.Handle(notification);
            }
        }