Package google.registry.util
Class SystemSleeper
- java.lang.Object
-
- google.registry.util.SystemSleeper
-
- All Implemented Interfaces:
Sleeper
,java.io.Serializable
@ThreadSafe public final class SystemSleeper extends java.lang.Object implements Sleeper, java.io.Serializable
Implementation ofSleeper
for production use.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description SystemSleeper()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
sleep(org.joda.time.ReadableDuration duration)
Puts the current thread to sleep.void
sleepUninterruptibly(org.joda.time.ReadableDuration duration)
Puts the current thread to sleep, ignoring interrupts.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface google.registry.util.Sleeper
sleepInterruptibly
-
-
-
-
Method Detail
-
sleep
public void sleep(org.joda.time.ReadableDuration duration) throws java.lang.InterruptedException
Description copied from interface:Sleeper
Puts the current thread to sleep.
-
sleepUninterruptibly
public void sleepUninterruptibly(org.joda.time.ReadableDuration duration)
Description copied from interface:Sleeper
Puts the current thread to sleep, ignoring interrupts.If
InterruptedException
was caught, thenThread.currentThread().interrupt()
will be called at the end of theduration
.- Specified by:
sleepUninterruptibly
in interfaceSleeper
- See Also:
Uninterruptibles.sleepUninterruptibly(java.time.Duration)
-
-