public class WaitFor
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static interface |
WaitFor.Condition |
Constructor and Description |
---|
WaitFor() |
Modifier and Type | Method and Description |
---|---|
static boolean |
waitFor(WaitFor.Condition condition,
long time,
java.util.concurrent.TimeUnit unit,
long sleepMs)
Static method used to wait for a specific condition to be satisfied.
|
public static boolean waitFor(WaitFor.Condition condition, long time, java.util.concurrent.TimeUnit unit, long sleepMs)
condition
- The condition to checktime
- The maximum time to wait for the condition to become trueunit
- The time unit of the time
argumentsleepMs
- The time to wait between checks