Package ai.platon.pulsar.crawl.event
Class WebPageWebDriverEventHandler
-
- All Implemented Interfaces:
-
ai.platon.pulsar.common.lang.ChainedHandler,ai.platon.pulsar.common.lang.PDFunction2,ai.platon.pulsar.common.lang.PFunction,ai.platon.pulsar.common.lang.PHandler
public class WebPageWebDriverEventHandler extends AbstractChainedPDFunction2<WebPage, WebDriver, Any>
An event handler that accepts a WebPage and a WebDriver, anything can be returned. The event handler is supposed to use the Web driver to interact with the active remote web page.
The Web asset might be changed by the handler since WebPage has setters.
If the Web asset is not supposed to be changed, readonly handlers should be used which accept a WebAsset instead of WebPage.
Another possible way to write more robust code is to remove all setters in WebPage, and add a MutableWebPage subclass.
-
-
Constructor Summary
Constructors Constructor Description WebPageWebDriverEventHandler()
-
Method Summary
Modifier and Type Method Description -
Methods inherited from class ai.platon.pulsar.common.lang.ChainedHandler
isEmpty, isNotEmpty -
Methods inherited from class ai.platon.pulsar.common.lang.AbstractPFunction
getName, getPriority, isRelevant -
Methods inherited from class ai.platon.pulsar.common.lang.AbstractChainedPDFunction2
addFirst, addFirst, addLast, addLast, clear, getSize, invoke, remove -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-