Class DevTools

java.lang.Object
org.openqa.selenium.devtools.DevTools
All Implemented Interfaces:
Closeable, AutoCloseable

public class DevTools extends Object implements Closeable
  • Constructor Details

  • Method Details

    • getDomains

      public Domains getDomains()
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
    • disconnectSession

      public void disconnectSession()
    • send

      public <X> X send(Command<X> command)
    • addListener

      public <X> void addListener(Event<X> event, Consumer<X> handler)
    • clearListeners

      public void clearListeners()
    • createSessionIfThereIsNotOne

      public void createSessionIfThereIsNotOne()
    • createSessionIfThereIsNotOne

      public void createSessionIfThereIsNotOne(String windowHandle)
    • createSession

      public void createSession()
    • createSession

      public void createSession(String windowHandle)
      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 of WebDriver.getWindowHandle(), optional.
    • getCdpSession

      public SessionID getCdpSession()