public void Constructor_ValidReason_SetsPublicProperty()
        {
            string reason = "aaa";
            PageLinksCrawlDisallowedArgs args = new PageLinksCrawlDisallowedArgs(_context, _page, reason);

            Assert.AreSame(reason, args.DisallowedReason);
        }
Esempio n. 2
0
 private void ThrowExceptionWhen_PageLinksCrawlDisallowed(object sender, PageLinksCrawlDisallowedArgs e)
 {
     throw new Exception("Oh No!");
 }
Esempio n. 3
0
 void crawler_PageLinksCrawlDisallowed(object sender, PageLinksCrawlDisallowedArgs e)
 {
     CrawledPage crawledPage = e.CrawledPage;
     Console.WriteLine("Did not crawl the links on page {0} due to {1}", crawledPage.Uri.AbsoluteUri, e.DisallowedReason);
 }
Esempio n. 4
0
 static void crawler_PageLinksCrawlDisallowed(object sender, PageLinksCrawlDisallowedArgs e)
 {
     //Process data
 }
Esempio n. 5
0
 static void crawler_PageLinksCrawlDisallowed(object sender, PageLinksCrawlDisallowedArgs e)
 {
     CrawledPage crawledPage = e.CrawledPage;
     // Debug.WriteLine(string.Format("Did not crawl the links on page {0} due to {1}", crawledPage.Uri.AbsoluteUri, e.DisallowedReason));
 }
Esempio n. 6
0
 private void crawler_PageLinksCrawlDisallowed(object sender, PageLinksCrawlDisallowedArgs e)
 {
     CrawledPage crawledPage = e.CrawledPage;
     var mssg = string.Format("Did not crawl the links on page {0} due to {1}", crawledPage.Uri.AbsoluteUri, e.DisallowedReason);
     _logger.Debug(mssg);
 }
 private void PageLinksCrawlDisallowedEvent(object sender, PageLinksCrawlDisallowedArgs e)
 {
 }