public final class Pause extends Object
Modifier and Type | Method and Description |
---|---|
static void |
pause()
Sleeps for 10 milliseconds.
|
static void |
pause(Condition condition)
Waits until the given condition is satisfied.
|
static void |
pause(Condition[] conditions)
Waits until the given conditions are satisfied.
|
static void |
pause(Condition[] conditions,
long timeout)
Waits until the given conditions are satisfied.
|
static void |
pause(Condition[] conditions,
Timeout timeout)
Waits until the given conditions are satisfied.
|
static void |
pause(Condition condition,
long timeout)
Waits until the given condition is satisfied.
|
static void |
pause(Condition condition,
Timeout timeout)
Waits until the given condition is satisfied.
|
static void |
pause(long ms)
Sleeps for the specified time.
|
static void |
pause(long timeout,
TimeUnit unit)
Sleeps for the specified time.
|
public static void pause(@Nonnull Condition condition)
condition
- the condition to verify.NullPointerException
- if the given condition is null
.WaitTimedOutError
- if the wait times out (more than 30 seconds).public static void pause(@Nonnull Condition condition, @Nonnull Timeout timeout)
condition
- the condition to verify.timeout
- the timeout.NullPointerException
- if the given timeout is null
.NullPointerException
- if the given condition is null
.WaitTimedOutError
- if the wait times out.public static void pause(@Nonnull Condition condition, long timeout)
condition
- the condition to verify.timeout
- the timeout (in milliseconds).NullPointerException
- if the given condition is null
.WaitTimedOutError
- if the wait times out.public static void pause(@Nonnull Condition[] conditions)
conditions
- the conditions to verify.NullPointerException
- if the array of conditions is null
.IllegalArgumentException
- if the array of conditions is empty.NullPointerException
- if the array of conditions has one or more null
values.WaitTimedOutError
- if the wait times out (more than 30 seconds).public static void pause(@Nonnull Condition[] conditions, @Nonnull Timeout timeout)
conditions
- the conditions to verify.timeout
- the timeout.NullPointerException
- if the given timeout is null
.NullPointerException
- if the array of conditions is null
.IllegalArgumentException
- if the array of conditions is empty.NullPointerException
- if the array of conditions has one or more null
values.WaitTimedOutError
- if the wait times out.public static void pause(@Nonnull Condition[] conditions, long timeout)
conditions
- the conditions to verify.timeout
- the timeout (in milliseconds).NullPointerException
- if the array of conditions is null
.IllegalArgumentException
- if the array of conditions is empty.NullPointerException
- if the array of conditions has one or more null
values.WaitTimedOutError
- if the wait times out.public static void pause(long timeout, @Nonnull TimeUnit unit)
timeout
- the quantity of time units to sleep.unit
- the time units.NullPointerException
- if unit
is null
.pause(long)
public static void pause(long ms)
Sleeps for the specified time.
To catch any InterruptedException
s that occur, Thread#sleep(long)
may be used instead.
ms
- the time to sleep in milliseconds.public static void pause()
Copyright © 2014–2017 AssertJ. All rights reserved.