public void Add(IHandleRequests instance) { if (_handlerFactory == null) throw new ArgumentException("An instance of a handler can not be added without a HandlerFactory."); _trackedObjects.Add(instance); _logger.Value.DebugFormat("Tracking instance {0} of type {1}", instance.GetHashCode(), instance.GetType()); }
public void Add(IHandleRequests instance) { _trackedObjects.Add(instance); if (_logger != null) { _logger.DebugFormat("Tracking instance {0} of type {1}", instance.GetHashCode(), instance.GetType()); } }
public void Add(IHandleRequests instance) { if (_handlerFactory == null) { throw new ArgumentException("An instance of a handler can not be added without a HandlerFactory."); } _trackedObjects.Add(instance); _logger.Value.DebugFormat("Tracking instance {0} of type {1}", instance.GetHashCode(), instance.GetType()); }
public void Add(IHandleRequests instance) { _trackedObjects.Add(instance); if (_logger != null) _logger.DebugFormat("Tracking instance {0} of type {1}", instance.GetHashCode(), instance.GetType()); }
public void Add(IHandleRequests instance) { if (_handlerFactorySync == null) { throw new ArgumentException("An instance of a handler can not be added without a HandlerFactory."); } _trackedObjects.Add(instance); s_logger.LogDebug("Tracking instance {InstanceHashCode} of type {HandlerType}", instance.GetHashCode(), instance.GetType()); }