Package org.openqa.selenium.devtools
Class DevTools
java.lang.Object
org.openqa.selenium.devtools.DevTools
- All Implemented Interfaces:
Closeable
,AutoCloseable
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<X> void
addListener
(Event<X> event, Consumer<X> handler) void
void
close()
void
void
createSession
(String windowHandle) Create CDP session on given window/tab (aka target).void
void
createSessionIfThereIsNotOne
(String windowHandle) void
<X> X
-
Constructor Details
-
DevTools
-
-
Method Details
-
getDomains
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
-
disconnectSession
public void disconnectSession() -
send
-
addListener
-
clearListeners
public void clearListeners() -
createSessionIfThereIsNotOne
public void createSessionIfThereIsNotOne() -
createSessionIfThereIsNotOne
-
createSession
public void createSession() -
createSession
Create CDP session on given window/tab (aka target). If windowHandle is null, then the first "page" type will be selected. Pass the windowHandle if you have multiple windows/tabs opened to connect to the expected window/tab.- Parameters:
windowHandle
- result ofWebDriver.getWindowHandle()
, optional.
-
getCdpSession
-