Exemple #1
0
        public IEventDataWriter AddLogWriter(string name, IEventDataWriter eventDataWriter)
        {
            Verify.IsNotNull(nameof(eventDataWriter), eventDataWriter);

            this.Register(name, (x, _) => eventDataWriter.Write(x));

            lock (_lock)
            {
                _eventDataWriters.Add(eventDataWriter);
            }

            return(eventDataWriter);
        }
 public void Post(EventData eventData)
 {
     _logWriter.Write(eventData);
 }