Class DevTools

  • All Implemented Interfaces:, java.lang.AutoCloseable

    public class DevTools
    extends java.lang.Object
    • Method Detail

      • getDomains

        public Domains getDomains()
      • close

        public void close()
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface
      • disconnectSession

        public void disconnectSession()
      • send

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

        public <X> void addListener​(Event<X> event,
                                    java.util.function.Consumer<X> handler)
      • clearListeners

        public void clearListeners()
      • createSessionIfThereIsNotOne

        public void createSessionIfThereIsNotOne()
      • createSessionIfThereIsNotOne

        public void createSessionIfThereIsNotOne​(java.lang.String windowHandle)
      • createSession

        public void createSession()
      • createSession

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

        public SessionID getCdpSession()