예제 #1
0
 public UriProcessor(ICrawlTaskRepository queue, ICrawlHandler handler)
 {
     _queue                   = queue;
     _immidiateCrawls         = new ConcurrentDictionary <ICrawlTask, AsyncManualResetEvent>();
     _immidiateCompletedTasks = new ConcurrentDictionary <ICrawlTask, WebDocument>();
     if (handler != null)
     {
         _onDocumentFetched = handler.OnDocumentFetched;
     }
     _waitHandle = new ManualResetEvent(false);
 }
예제 #2
0
 public Crawler(ICrawlHandler handler)
 {
     _handler = handler;
 }