Class DefaultBrowserInteractionService

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void deleteAllCookies()
      Delete all the cookies for the current domain.
      java.lang.String getTitle()
      Returns the title of the current page.
      void openURL​(java.lang.String url)
      Load a new web page in the current browser window.
      void refresh()
      Refresh the current page
      void switchToFrame​(java.lang.String frameNameOrId)
      Select a frame by its name or ID.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DefaultBrowserInteractionService

        public DefaultBrowserInteractionService()
    • Method Detail

      • openURL

        public void openURL​(java.lang.String url)
        Description copied from interface: BrowserInteractionService
        Load a new web page in the current browser window. This is done using an HTTP GET operation, and the method will block until the load is complete. This will follow redirects issued either by the server or as a meta-redirect from within the returned HTML. Should a meta-redirect "rest" for any duration of time, it is best to wait until this timeout is over, since should the underlying page change whilst your test is executing the results of future calls against this interface will be against the freshly loaded page. Synonym for WebDriver.Navigation.to(String).
        Specified by:
        openURL in interface BrowserInteractionService
        Parameters:
        url - The URL to load. It is best to use a fully qualified URL
      • getTitle

        public java.lang.String getTitle()
        Description copied from interface: BrowserInteractionService
        Returns the title of the current page.
        Specified by:
        getTitle in interface BrowserInteractionService
        Returns:
        The title of the current page, with leading and trailing whitespace stripped, or null if one is not already set
      • switchToFrame

        public void switchToFrame​(java.lang.String frameNameOrId)
        Description copied from interface: BrowserInteractionService
        Select a frame by its name or ID. Frames located by matching name attributes are always given precedence over those matched by ID.
        Specified by:
        switchToFrame in interface BrowserInteractionService
        Parameters:
        frameNameOrId - the name of the frame window, the id of the <frame> or <iframe> element, or the (zero-based) index