-
- All Implemented Interfaces:
-
ai.platon.pulsar.crawl.fetch.driver.BrowserInstance,java.lang.AutoCloseable
public final class PlaywrightBrowserInstance extends AbstractBrowserInstance
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public classPlaywrightBrowserInstance.Companion
-
Field Summary
Fields Modifier and Type Field Description private final ConcurrentLinkedQueue<PlaywrightDriver>driversprivate final IntegerdriverCountprivate final StringpreloadJsprivate InstantactiveTimeprivate final BrowserInstanceIdidprivate final DurationidleTimeoutprivate final BooleanisGUIprivate final BooleanisIdleprivate final ChromeOptionslaunchOptionsprivate final LauncherOptionslauncherOptionsprivate final List<NavigateEntry>navigateHistoryprivate final ThreadshutdownHookThreadprivate final AtomicIntegertabCount
-
Constructor Summary
Constructors Constructor Description PlaywrightBrowserInstance(BrowserInstanceId id, LauncherOptions launcherOptions, ChromeOptions launchOptions)
-
Method Summary
Modifier and Type Method Description final ConcurrentLinkedQueue<PlaywrightDriver>getDrivers()final IntegergetDriverCount()final StringgetPreloadJs()final InstantgetActiveTime()final UnitsetActiveTime(Instant activeTime)BrowserInstanceIdgetId()final DurationgetIdleTimeout()final BooleangetIsGUI()BooleangetIsIdle()ChromeOptionsgetLaunchOptions()LauncherOptionsgetLauncherOptions()List<NavigateEntry>getNavigateHistory()ThreadgetShutdownHookThread()AtomicIntegergetTabCount()Unitlaunch()final PagecreateTab()final UnitcloseTab(Page page)Unitclose()-
-
Method Detail
-
getDrivers
final ConcurrentLinkedQueue<PlaywrightDriver> getDrivers()
-
getDriverCount
final Integer getDriverCount()
-
getPreloadJs
final String getPreloadJs()
-
getActiveTime
final Instant getActiveTime()
-
setActiveTime
final Unit setActiveTime(Instant activeTime)
-
getId
BrowserInstanceId getId()
-
getIdleTimeout
final Duration getIdleTimeout()
-
getLaunchOptions
ChromeOptions getLaunchOptions()
-
getLauncherOptions
LauncherOptions getLauncherOptions()
-
getNavigateHistory
List<NavigateEntry> getNavigateHistory()
-
getShutdownHookThread
Thread getShutdownHookThread()
-
getTabCount
AtomicInteger getTabCount()
-
createTab
@Synchronized() final Page createTab()
-
closeTab
@Synchronized() final Unit closeTab(Page page)
-
-
-
-