Esempio n. 1
0
 public WikiReferencesCollector(
     IPageDownloadService pageDownloadService,
     IFileSystemService fileSystemService,
     IWikiReferencesParsingService wikiReferencesParser,
     IReferencesDbService referencesDbService,
     IIoDevice ioDevice)
 {
     this.folderPath                     = ConfigurationManager.AppSettings["FolderPath"];
     this.maxIterations                  = int.Parse(ConfigurationManager.AppSettings["MaxIterations"]);
     this.startPage                      = ConfigurationManager.AppSettings["StartPage"];
     this.pageDownloadService            = pageDownloadService;
     this.pageDownloadService.BaseAdress = ConfigurationManager.AppSettings["Uri"];
     this.fileSystemService              = fileSystemService;
     this.wikiReferencesParsingService   = wikiReferencesParser;
     this.referencesDbService            = referencesDbService;
     this.ioDevice = ioDevice;
     this.mutexObj = new Mutex(true, "ReferenceCollector", out canRun);
     dbLock        = new object();
 }
Esempio n. 2
0
 public void Initialize()
 {
     fileSystemRepository = new FileSystemRepository();
     parsingService       = new WikiReferencesParsingService(fileSystemRepository);
 }