org.openqa.selenium.support.ui

Class WebDriverWait

  • All Implemented Interfaces:
    Wait<org.openqa.selenium.WebDriver>


    public class WebDriverWaitextends FluentWait<org.openqa.selenium.WebDriver>
    A specialization of FluentWait that uses WebDriver instances.
    • Field Detail

    • Constructor Detail

      • WebDriverWait

        public WebDriverWait(org.openqa.selenium.WebDriver driver,                     long timeOutInSeconds)
        Wait will ignore instances of NotFoundException that are encountered (thrown) by default in the 'until' condition, and immediately propagate all others. You can add more to the ignore list by calling ignoring(exceptions to add).
        Parameters:
        driver - The WebDriver instance to pass to the expected conditions
        timeOutInSeconds - The timeout in seconds when an expectation is called
        See Also:
        FluentWait.ignoring(java.lang.Class)
      • WebDriverWait

        public WebDriverWait(org.openqa.selenium.WebDriver driver,                     long timeOutInSeconds,                     long sleepInMillis)
        Wait will ignore instances of NotFoundException that are encountered (thrown) by default in the 'until' condition, and immediately propagate all others. You can add more to the ignore list by calling ignoring(exceptions to add).
        Parameters:
        driver - The WebDriver instance to pass to the expected conditions
        timeOutInSeconds - The timeout in seconds when an expectation is called
        sleepInMillis - The duration in milliseconds to sleep between polls.
        See Also:
        FluentWait.ignoring(java.lang.Class)
      • WebDriverWait

        public WebDriverWait(org.openqa.selenium.WebDriver driver,                     Clock clock,                     Sleeper sleeper,                     long timeOutInSeconds,                     long sleepTimeOut)
        Parameters:
        driver - The WebDriver instance to pass to the expected conditions
        clock - The clock to use when measuring the timeout
        sleeper - Object used to make the current thread go to sleep.
        timeOutInSeconds - The timeout in seconds when an expectation is
        sleepTimeOut - The timeout used whilst sleeping. Defaults to 500ms called.
    • Method Detail

      • timeoutException

        protected RuntimeException timeoutException(String message,                                            Throwable lastException)
        Description copied from class: FluentWait
        Throws a timeout exception. This method may be overridden to throw an exception that is idiomatic for a particular test infrastructure, such as an AssertionError in JUnit4.
        Overrides:
        timeoutException in class FluentWait<org.openqa.selenium.WebDriver>
        Parameters:
        message - The timeout message.
        lastException - The last exception to be thrown and subsequently suppressed while waiting on a function.
        Returns:
        Nothing will ever be returned; this return type is only specified as a convenience.

Copyright © 2016. All rights reserved.



NOTHING
NOTHING
Add the Maven Dependecy to your project: maven dependecy for com.amazonaws : aws-java-sdk : 1.3.14