Package org.fest.swing.timing
Class Condition
java.lang.Object
org.fest.swing.timing.Condition
- Direct Known Subclasses:
ComponentEnabledCondition
,ComponentFoundCondition
,EdtSafeCondition
,JTreeChildrenShowUpCondition
,WaitForComponentToShowCondition
Understands a condition to verify, usually used in the method
Pause.pause(Condition)
.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final org.fest.assertions.Description
protected static final String
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate String
protected String
Returns any text to be added to this condition's description.protected void
done()
Notification that this condition has been evaluated.abstract boolean
test()
Checks if the condition has been satisfied.final String
toString()
Returns theString
representation of this condition, which is its description.
-
Field Details
-
EMPTY_TEXT
- See Also:
-
description
private final org.fest.assertions.Description description
-
-
Constructor Details
-
Method Details
-
test
public abstract boolean test()Checks if the condition has been satisfied.- Returns:
true
if the condition has been satisfied, otherwisefalse
.
-
toString
Returns theString
representation of this condition, which is its description. -
defaultDescription
-
descriptionAddendum
Returns any text to be added to this condition's description. The default value is an emptyString
.- Returns:
- by default, an empty
String
.
-
done
protected void done()Notification that this condition has been evaluated. This method is invoked by
(and all overloaded methods) when this condition is evaluated (either it was satisfied or it timed-out.) This is a good place to do any necessary resource cleanup.Pause.pause(Condition)
-