@InterfaceAudience.Private public class Sleeper extends Object
Modifier and Type | Method and Description |
---|---|
int |
getPeriod() |
void |
skipSleepCycle()
If currently asleep, stops sleeping; if not asleep, will skip the next
sleep cycle.
|
void |
sleep()
Sleep for period.
|
void |
sleep(long sleepTime) |
public Sleeper(int sleep, Stoppable stopper)
sleep
- sleep time in millisecondsstopper
- When Stoppable.isStopped()
is true, this thread will
cleanup and exit cleanly.public void skipSleepCycle()
public void sleep()
public void sleep(long sleepTime)
public final int getPeriod()
Copyright © 2007–2019 Cloudera. All rights reserved.