public NotificationManager(DataNotificationLoader loader) { if (loader != null) { loaders.Add(loader); } }
public NotificationManager(TypeNotification type) { this.type = type; switch (type) { case TypeNotification.DublicatePipeNumber: strategyFill = new DublicateNumberFill(); loader = new DublicateNumberLoader(this); break; case TypeNotification.ExpiredCertificate: this.strategyFill = new InspectorCertificateFill(); loader = new InspectorCertificateLoader(this); break; case TypeNotification.WelderCertificateExpired: strategyFill = new WelderCertificateFill(); loader = new WelderCertificateLoader(this); break; case TypeNotification.DublicateLogin: strategyFill = new DublicateLoginFill(); loader = new DuplicateLoginLoader(this); break; default: var ex = new NotImplementedException(); log.Error(ex.Message); throw ex; //break; // unreachable code } }
protected void AddLoader(DataNotificationLoader loader) { loaders.Add(loader); }