|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface Sleeper
Something that can sleep.
| Nested Class Summary | |
|---|---|
static class |
Sleeper.ShutdownException
Exception used to indicate that a Sleeper has been shutdown. |
| Method Summary | |
|---|---|
void |
shutdown()
Shutdown this Sleeper. |
void |
sleepFlat(long maximumTime)
Sleep for a time based on the maximumTime parameter. |
void |
sleepNormal(long meanTime)
Sleep for a time based on the meanTime parameter. |
void |
sleepNormal(long meanTime,
long sigma)
Sleep for a random time drawn from a pseudo normal distribution. |
| Methods inherited from interface net.grinder.util.TimeAuthority |
|---|
getTimeInMilliseconds |
| Method Detail |
|---|
void shutdown()
Sleeper. Once called, all sleep method
invocations will throw Sleeper.ShutdownException,
including those already sleeping.
void sleepNormal(long meanTime)
throws Sleeper.ShutdownException
meanTime - Mean time.
Sleeper.ShutdownException - If this Sleeper has been shutdown.
void sleepNormal(long meanTime,
long sigma)
throws Sleeper.ShutdownException
meanTime - Mean time.sigma - Standard deviation.
Sleeper.ShutdownException - If this Sleeper has been shutdown.
void sleepFlat(long maximumTime)
throws Sleeper.ShutdownException
maximumTime - Maximum time.
Sleeper.ShutdownException - If this Sleeper has been shutdown.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||