public class DefaultAjaxWaiting extends DefaultWaiting<AjaxWaiting> implements AjaxWaiting
Implementation of waiting for satisfaction of conditions on page after the Ajax request.
It uses custom JavaScript and com.thoughtworks.selenium.Selenium.Selenium#waitForCondition(String, String) to wait for satisfying given condition.
| Constructor and Description |
|---|
DefaultAjaxWaiting() |
| Modifier and Type | Method and Description |
|---|---|
void |
until(JavaScriptCondition condition)
Stars loop waiting to satisfy condition.
|
<T> void |
waitForChange(JavaScriptRetriever<T> retriever)
Waits until Retrieve's implementation doesn't retrieve value other than value stored by initialization in retriever.
|
<T> void |
waitForChange(T oldValue,
JavaScriptRetriever<T> retriever)
Waits until Retrieve's implementation doesn't retrieve value other than oldValue.
|
<T> T |
waitForChangeAndReturn(JavaScriptRetriever<T> retriever)
Waits until Retrieve's implementation doesn't retrieve value other than value stored by initialization in retriever.
|
<T> T |
waitForChangeAndReturn(T oldValue,
JavaScriptRetriever<T> retriever)
Waits until Retrieve's implementation doesn't retrieve value other than oldValue and this new value returns.
|
dontFail, fail, failWith, failWith, getInterval, getTimeout, interval, isDelayed, noDelay, timeout, waitForTimeout, withDelaypublic void until(JavaScriptCondition condition)
until in interface AjaxWaitingcondition - what wait for to be satisfiedpublic <T> void waitForChange(T oldValue,
JavaScriptRetriever<T> retriever)
waitForChange in interface AjaxWaitingT - type of value what we are waiting for changeoldValue - value that we are waiting for changeretriever - implementation of retrieving actual valuepublic <T> void waitForChange(JavaScriptRetriever<T> retriever)
Waits until Retrieve's implementation doesn't retrieve value other than value stored by initialization in retriever.
After retrieving, new value will be associated with given Retriever.
Note that Retriever needs to be initialized first by one of methods
RetrievedValueHolder.initializeValue() or
RetrievedValueHolder.setValue(Object) .
waitForChange in interface AjaxWaitingT - type of value what we are waiting for changeretriever - implementation of retrieving actual valuepublic <T> T waitForChangeAndReturn(T oldValue,
JavaScriptRetriever<T> retriever)
waitForChangeAndReturn in interface AjaxWaitingT - type of value what we are waiting for changeoldValue - value that we are waiting for changeretriever - implementation of retrieving actual valuepublic <T> T waitForChangeAndReturn(JavaScriptRetriever<T> retriever)
Waits until Retrieve's implementation doesn't retrieve value other than value stored by initialization in retriever.
After retrieving, new value will be associated with given Retriever.
Note that Retriever needs to be initialized first by one of methods
RetrievedValueHolder.initializeValue() or
RetrievedValueHolder.setValue(Object) .
waitForChangeAndReturn in interface AjaxWaitingT - type of value what we are waiting for changeretriever - implementation of retrieving actual valueCopyright © 2013 JBoss by Red Hat. All Rights Reserved.