org.eclipse.swtbot.swt.finder.waits
Class WaitForObjectCondition<T>
java.lang.Object
org.eclipse.swtbot.swt.finder.waits.DefaultCondition
org.eclipse.swtbot.swt.finder.waits.WaitForObjectCondition<T>
- All Implemented Interfaces:
- ICondition
- Direct Known Subclasses:
- WaitForEditor, WaitForView
public abstract class WaitForObjectCondition<T>
- extends DefaultCondition
Waits for objects to appear until the matcher evaluates to true.
- Version:
- $Id$
- Author:
- Ketan Padegaonkar <KetanPadegaonkar [at] gmail [dot] com>
- See Also:
Conditions
Field Summary |
protected Matcher<T> |
matcher
The matcher that is used to match widgets. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
matcher
protected final Matcher<T> matcher
- The matcher that is used to match widgets.
WaitForObjectCondition
public WaitForObjectCondition(Matcher<T> matcher)
- Waits until the matcher is true.
- Parameters:
matcher
- the matcher.
test
public boolean test()
throws Exception
- Description copied from interface:
ICondition
- Tests if the condition has been met.
- Returns:
true
if the condition is satisfied, false
otherwise.
- Throws:
Exception
- if the test encounters an error while processing the check.
findMatches
protected abstract List<T> findMatches()
- Returns:
- the matches that subclasses that matched.
getAllMatches
public List<T> getAllMatches()
- Returns:
- all objects that matched the matcher.
get
public T get(int index)
- Parameters:
index
- the index of the object.
- Returns:
- the element at the specified index in the list of matched objects.