Package io.fluentlenium.core.wait
Interface FluentWaitConfiguration<T>
- Type Parameters:
T-thisobject type to chain method calls
- All Known Implementing Classes:
FluentWait,FluentWaitElement,FluentWaitElementList
public interface FluentWaitConfiguration<T>
Configuration API of fluent wait object.
-
Method Summary
Modifier and TypeMethodDescriptiondefault TatMost(long duration) Configure wait timeout for this wait object.default TConfigure timeout for this wait object.Configure timeout for this wait object.org.openqa.selenium.support.ui.FluentWaitgetWait()Get the underlying selenium wait objectbooleanCheck if a message is defined.ignoreAll(Collection<Class<? extends Throwable>> types) Add given exceptions to ignore list to avoid breaking the wait when they occurs in the underlying condition evaluation.ignoring(Class<? extends RuntimeException> exceptionType) Add given exception to ignore list to avoid breaking the wait when they occurs in the underlying condition evaluation.ignoring(Class<? extends RuntimeException> firstType, Class<? extends RuntimeException> secondType) Add given exceptions to ignore list to avoid breaking the wait when they occurs in the underlying condition evaluation.default TpollingEvery(long duration) Configure polling time for this wait object.default TpollingEvery(long duration, TimeUnit unit) Configure polling time for this wait object.pollingEvery(Duration duration) Configure polling time for this wait object.default TwithMessage(String message) Configures a custom message to be used if the condition fails during the timeout duration.withMessage(Supplier<String> message) Configures a custom message supplier to be used if the condition fails during the timeout duration.Removes default exceptions from exceptions ignore list.
-
Method Details
-
getWait
org.openqa.selenium.support.ui.FluentWait getWait()Get the underlying selenium wait object- Returns:
- selenium wait
-
atMost
Configure timeout for this wait object.- Parameters:
duration- duration- Returns:
thisobject to chain method calls
-
atMost
Configure timeout for this wait object.- Parameters:
duration- durationunit- time unit- Returns:
thisobject to chain method calls
-
atMost
Configure wait timeout for this wait object.- Parameters:
duration- duration in millisecond- Returns:
thisobject to chain method calls
-
pollingEvery
Configure polling time for this wait object.- Parameters:
duration- duration between each condition invocation- Returns:
thisobject to chain method calls
-
pollingEvery
Configure polling time for this wait object.- Parameters:
duration- duration between each condition invocationunit- time unit- Returns:
thisobject to chain method calls
-
pollingEvery
Configure polling time for this wait object.- Parameters:
duration- duration in millisecond between each condition invocation- Returns:
thisobject to chain method calls
-
ignoreAll
Add given exceptions to ignore list to avoid breaking the wait when they occurs in the underlying condition evaluation.- Parameters:
types- collection of exception type to ignore- Returns:
thisobject to chain method calls
-
ignoring
Add given exception to ignore list to avoid breaking the wait when they occurs in the underlying condition evaluation.- Parameters:
exceptionType- exception type to ignore- Returns:
thisobject to chain method calls
-
ignoring
T ignoring(Class<? extends RuntimeException> firstType, Class<? extends RuntimeException> secondType) Add given exceptions to ignore list to avoid breaking the wait when they occurs in the underlying condition evaluation.- Parameters:
firstType- exception type to ignoresecondType- exception type to ignore- Returns:
thisobject to chain method calls
-
withMessage
Configures a custom message to be used if the condition fails during the timeout duration.- Parameters:
message- failing message- Returns:
thisobject to chain method calls
-
withMessage
Configures a custom message supplier to be used if the condition fails during the timeout duration.- Parameters:
message- failing message- Returns:
thisobject to chain method calls
-
hasMessageDefined
boolean hasMessageDefined()Check if a message is defined.- Returns:
- true if this fluent wait use a custom message, false otherwise
-
withNoDefaultsException
T withNoDefaultsException()Removes default exceptions from exceptions ignore list.- Returns:
thisobject to chain method calls
-