Class MockSleeper
- java.lang.Object
-
- com.google.api.client.testing.util.MockSleeper
-
-
Constructor Summary
Constructors Constructor Description MockSleeper()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetCount()Returns the number of timessleep(long)was called.longgetLastMillis()voidsleep(long millis)Causes the currently executing thread to sleep (temporarily cease execution) for the specified number of milliseconds as specified inThread.sleep(long).
-
-
-
Method Detail
-
sleep
public void sleep(long millis) throws InterruptedExceptionDescription copied from interface:SleeperCauses the currently executing thread to sleep (temporarily cease execution) for the specified number of milliseconds as specified inThread.sleep(long).- Specified by:
sleepin interfaceSleeper- Parameters:
millis- length of time to sleep in milliseconds- Throws:
InterruptedException- if any thread has interrupted the current thread
-
getCount
public final int getCount()
Returns the number of timessleep(long)was called.
-
getLastMillis
public final long getLastMillis()
-
-