This is an old revision of the document!
Crawler Plugins hook into the crawling process in order to add advanced functionality.
Some examples:
onBeforePrepare
)onAfterPrepare
)CrawlerPlugin
.Plugin-Class
must be set to the complete class name of the implementing class.plugins
-Directory.
void onStartCrawling(Crawler crawler)
Called before the crawling process starts (Crawler::run()
).
This may be called multiple times during the lifetime of a plugin instance, but [Crawler Plugins#onFinishCrawling|onFinishCrawling()] is always called in between.
Parameters:
Paramter Name | Description |
---|---|
crawler | The crawler instance that is about to begin crawling |
void onFinishCrawling(Crawler crawler)
Called after the crawling process has finished or aborted (because of an exception).
This may be called multiple times during the lifetime of a plugin instance.
Parameters:
Paramter Name | Description |
---|---|
crawler | The crawler instance that is about to begin crawling |