/// <summary> /// Adds handlers for EventRecords (thread safe) /// </summary> public void AddHandler(IEventRecordHandler handler) { handlersLock.EnterWriteLock(); try { handlers.Add(handler); } finally { handlersLock.ExitWriteLock(); } }
/// <summary> /// Removes handler for EventRecords (thread safe) /// </summary> public void RemoveHandler(IEventRecordHandler handler) { handlersLock.EnterWriteLock(); try { handlers.Remove(handler); } finally { handlersLock.ExitWriteLock(); } }