Exemple #1
0
 public ValidationService
 (
     System.Globalization.CultureInfo targetCulture,
     IEnumerable <IInterpreter> interpreters,
     IEnumerable <IValidator> contentValidators,
     IEnumerable <Logging.ILog> logs,
     IEnumerable <Logging.ITimedLog> timedLogs,
     XmlRetrieval.ISource <T> source,
     XmlCachingResolver xmlCachingResolver
 )
 {
     this.AttemptSchemaLocationInjection = true;
     this.Source             = source;
     this.TargetCulture      = targetCulture;
     this.XmlCachingResolver = xmlCachingResolver;
     if (null != interpreters)
     {
         this.XmlExceptionInterpreters = new List <IInterpreter>(interpreters.OrderBy(i => i.Order));
     }
     else
     {
         this.XmlExceptionInterpreters = new List <IInterpreter>();
     }
     if (null != contentValidators)
     {
         this.XmlContentValidators = new List <IValidator>(contentValidators.OrderBy(cv => cv.Order));
     }
     else
     {
         this.XmlContentValidators = new List <IValidator>();
     }
     if (null != logs)
     {
         this.Logs = new List <Logging.ILog>(logs);
     }
     else
     {
         this.Logs = new List <Logging.ILog>();
     }
     if (null != timedLogs)
     {
         this.TimedLogs = new List <Logging.ITimedLog>(timedLogs);
     }
     else
     {
         this.TimedLogs = new List <Logging.ITimedLog>();
     }
 }
Exemple #2
0
 public ValidationService
 (
     IEnumerable <IInterpreter> interpreters,
     IEnumerable <IValidator> contentValidators,
     IEnumerable <Logging.ILog> logs,
     IEnumerable <Logging.ITimedLog> timedLogs,
     XmlRetrieval.ISource <T> source,
     XmlCachingResolver xmlCachingResolver
 )
     : this
     (
         System.Globalization.CultureInfo.CurrentUICulture,
         interpreters,
         contentValidators,
         logs,
         timedLogs,
         source,
         xmlCachingResolver
     )
 {
 }