Class Frame.WaitForNavigationOptions

java.lang.Object
com.microsoft.playwright.Frame.WaitForNavigationOptions
Enclosing interface:
Frame

public static class Frame.WaitForNavigationOptions extends Object
  • Field Details

    • timeout

      public Double timeout
      Maximum operation time in milliseconds, defaults to 30 seconds, pass 0 to disable timeout. The default value can be changed by using the BrowserContext.setDefaultNavigationTimeout(), BrowserContext.setDefaultTimeout(), Page.setDefaultNavigationTimeout() or Page.setDefaultTimeout() methods.
    • url

      public Object url
      A glob pattern, regex pattern or predicate receiving [URL] to match while waiting for the navigation. Note that if the parameter is a string without wildcard characters, the method will wait for navigation to URL that is exactly equal to the string.
    • waitUntil

      public WaitUntilState waitUntil
      When to consider operation succeeded, defaults to load. Events can be either:
      • "domcontentloaded" - consider operation to be finished when the DOMContentLoaded event is fired.
      • "load" - consider operation to be finished when the load event is fired.
      • "networkidle" - **DISCOURAGED** consider operation to be finished when there are no network connections for at least 500 ms. Don't use this method for testing, rely on web assertions to assess readiness instead.
      • "commit" - consider operation to be finished when network response is received and the document started loading.
  • Constructor Details

    • WaitForNavigationOptions

      public WaitForNavigationOptions()
  • Method Details

    • setTimeout

      public Frame.WaitForNavigationOptions setTimeout(double timeout)
      Maximum operation time in milliseconds, defaults to 30 seconds, pass 0 to disable timeout. The default value can be changed by using the BrowserContext.setDefaultNavigationTimeout(), BrowserContext.setDefaultTimeout(), Page.setDefaultNavigationTimeout() or Page.setDefaultTimeout() methods.
    • setUrl

      A glob pattern, regex pattern or predicate receiving [URL] to match while waiting for the navigation. Note that if the parameter is a string without wildcard characters, the method will wait for navigation to URL that is exactly equal to the string.
    • setUrl

      A glob pattern, regex pattern or predicate receiving [URL] to match while waiting for the navigation. Note that if the parameter is a string without wildcard characters, the method will wait for navigation to URL that is exactly equal to the string.
    • setUrl

      A glob pattern, regex pattern or predicate receiving [URL] to match while waiting for the navigation. Note that if the parameter is a string without wildcard characters, the method will wait for navigation to URL that is exactly equal to the string.
    • setWaitUntil

      public Frame.WaitForNavigationOptions setWaitUntil(WaitUntilState waitUntil)
      When to consider operation succeeded, defaults to load. Events can be either:
      • "domcontentloaded" - consider operation to be finished when the DOMContentLoaded event is fired.
      • "load" - consider operation to be finished when the load event is fired.
      • "networkidle" - **DISCOURAGED** consider operation to be finished when there are no network connections for at least 500 ms. Don't use this method for testing, rely on web assertions to assess readiness instead.
      • "commit" - consider operation to be finished when network response is received and the document started loading.