override public void __Processor(BotCycle bc) { CustomBotCycle cbc = (CustomBotCycle)bc; int _MaxDownloadedFileLength = Cliver.BotWeb.Settings.Web.MaxDownloadedFileLength; if (!Download) { Cliver.BotWeb.Settings.Web.MaxDownloadedFileLength = 0; } bool rc = cbc.hr.GetPage(Url); Cliver.BotWeb.Settings.Web.MaxDownloadedFileLength = _MaxDownloadedFileLength; if (!rc) { if (cbc.hr.Status == WebRoutineStatus.UNACCEPTABLE_CONTENT_TYPE) { return; } if (cbc.hr.HWResponse.StatusCode == System.Net.HttpStatusCode.NotFound) { FileWriter.This.WriteLine(ParentLink.Url, Url); } //site2boken_urls[item.Site.Url] = site2boken_urls[item.Site.Url] + "\n" + item.Url; else { throw new ProcessorException(ProcessorExceptionType.RESTORE_AS_NEW, "Could not get: " + Url); } return; } if (Download) { cbc.get_links(Depth + 1); } }
override public void __Processor(BotCycle bc) { CustomBotCycle cbc = (CustomBotCycle)bc; string url = "http://www.yellowpages.com/search?search_terms=" + Keyword + "&geo_location_terms=" + Location; cbc.search_processor(url); }
override public void __Processor(BotCycle bc) { CustomBotCycle cbc = (CustomBotCycle)bc; if (!cbc.hr.GetPage(Url)) { throw new ProcessorException(ProcessorExceptionType.RESTORE_AS_NEW, "Could not get site: " + Url); } cbc.get_links(1); }
override public void __Processor(BotCycle bc) { CustomBotCycle cbc = (CustomBotCycle)bc; if (!cbc.HR.GetPage(Url)) { throw new ProcessorException(ProcessorExceptionType.RESTORE_AS_NEW, "Could not get: " + Url); } DataSifter.Capture c = yp2.Parse(cbc.HR.HtmlResult); FileWriter.This.PrepareAndWriteHtmlLineWithHeader( "Name", c.ValueOf("Name"), "City", c.ValueOf("City"), "ZipCode", c.ValueOf("ZipCode"), "State", c.ValueOf("State"), "Phone", c.ValueOf("Phone"), "Email", c.ValueOf("Email"), "Site", c.ValueOf("Site"), "Url", Url ); }
override public void __Processor(BotCycle bc) { CustomBotCycle cbc = (CustomBotCycle)bc; cbc.search_processor(Url); }