public class CrawlerContext extends Object
| Constructor and Description |
|---|
CrawlerContext(EmbeddedBrowser browser,
CrawljaxConfiguration config,
javax.inject.Provider<CrawlSession> sessionProvider,
ExitNotifier exitNotifier,
com.codahale.metrics.MetricRegistry registry) |
| Modifier and Type | Method and Description |
|---|---|
EmbeddedBrowser |
getBrowser() |
CrawljaxConfiguration |
getConfig() |
CrawlPath |
getCrawlPath() |
StateVertex |
getCurrentState() |
com.codahale.metrics.MetricRegistry |
getRegistry() |
CrawlSession |
getSession() |
protected void |
setCrawlPath(CrawlPath path) |
void |
stop()
Tells Crawljax to stop with Exit status
ExitNotifier.ExitStatus.STOPPED. |
@Inject public CrawlerContext(EmbeddedBrowser browser, CrawljaxConfiguration config, javax.inject.Provider<CrawlSession> sessionProvider, ExitNotifier exitNotifier, com.codahale.metrics.MetricRegistry registry)
public EmbeddedBrowser getBrowser()
EmbeddedBrowser that caused the given Plugin to fire.public CrawlSession getSession()
CrawlSessionpublic CrawljaxConfiguration getConfig()
CrawljaxConfiguration for this crawl.public void stop()
ExitNotifier.ExitStatus.STOPPED. This is equivalent to
calling CrawljaxRunner.stop().public StateVertex getCurrentState()
StateVertex or null when the Crawler isn't
initialized yet.public com.codahale.metrics.MetricRegistry getRegistry()
protected void setCrawlPath(CrawlPath path)
The - current CrawlPath in this context.Copyright © 2007–2013. All rights reserved.