* function for simple crawl of one url

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@7678 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
f1ori 14 years ago
parent d671de8c17
commit 0b02083e97

@ -330,9 +330,33 @@ public final class CrawlStacker {
}.start();
}
/**
* simple method to add one url as crawljob
* @param url
* @return null if successfull, a reason string if not successful
*/
public String stackSimpleCrawl(final DigestURI url) {
CrawlProfile pe = this.crawler.defaultSurrogateProfile;
return stackCrawl(new Request(
peers.mySeed().hash.getBytes(),
url,
null,
"CRAWLING-ROOT",
new Date(),
pe.handle(),
0,
0,
0,
0
));
}
/**
* stacks a crawl item. The position can also be remote
* @param entry
* @return null if successful, a reason string if not successful
*/
public String stackCrawl(final Request entry) {
// stacks a crawl item. The position can also be remote
// returns null if successful, a reason string if not successful
//this.log.logFinest("stackCrawl: nexturlString='" + nexturlString + "'");
final CrawlProfile profile = crawler.getActive(UTF8.getBytes(entry.profileHandle()));

Loading…
Cancel
Save