Example #1
0
 public XmlValidator()
 {
     memoryStreamFactory          = new MemoryStreamFactory();
     fileSystem                   = new FileSystem();
     xmlReaderSettingsFactory     = new XmlReaderSettingsFactory();
     validationErrorEventRiser    = new EventRiser <ValidationErrorEventArgs>();
     validationFinishedEventRiser = new EventRiser <ValidationFinishedEventArgs>();
     streamValidator              = new StreamUtils();
     xmlValidationUtils           = new XmlValidationUtils();
 }
Example #2
0
 public XmlValidator(
     IMemoryStreamFactory memoryStreamFactory = null,
     IFileSystem fileSystem = null,
     IXmlReaderSettingsFactory xmlReaderSettingsFactory = null,
     IEventRiserClass <ValidationErrorEventArgs> validationErrorEventRiser       = null,
     IEventRiserClass <ValidationFinishedEventArgs> validationFinishedEventRiser = null,
     IStreamValidator streamValidator       = null,
     IXmlValidationUtils xmlValidationUtils = null)
 {
     this.memoryStreamFactory          = memoryStreamFactory ?? new MemoryStreamFactory();
     this.fileSystem                   = fileSystem ?? new FileSystem();
     this.xmlReaderSettingsFactory     = xmlReaderSettingsFactory ?? new XmlReaderSettingsFactory();
     this.validationErrorEventRiser    = validationErrorEventRiser ?? new EventRiser <ValidationErrorEventArgs>();
     this.validationFinishedEventRiser = validationFinishedEventRiser ?? new EventRiser <ValidationFinishedEventArgs>();
     this.streamValidator              = streamValidator ?? new StreamUtils();
     this.xmlValidationUtils           = xmlValidationUtils ?? new XmlValidationUtils();
 }
 public void Setup()
 {
     fakeFileSystem     = A.Fake <IFileSystem>();
     xmlValidationUtils = new XmlValidationUtils();
 }