public SmtpServer() { Bindings = new ConcurrentBag<PortListener>(); Connections = new ConcurrentDictionary<EndPoint, SmtpConnection>(); Configuration = new SmtpServerConfiguration(); Watchdog = new IdleConnectionDisconnectWatchdog<SmtpServer>(this); WatchForConfigurationChange(); }
private static SmtpServerConfiguration CreateWithConfigurationChangedEvent(Action onChangedDelegate) { var config = new SmtpServerConfiguration(); config.ConfigurationChanged += c => onChangedDelegate(); return config; }