backtype.storm.utils
Class Time

java.lang.Object
  extended by backtype.storm.utils.Time

public class Time
extends java.lang.Object


Field Summary
static Logger LOG
           
 
Constructor Summary
Time()
           
 
Method Summary
static void advanceTime(long ms)
           
static long currentTimeMillis()
           
static int currentTimeSecs()
           
static boolean isSimulating()
           
static boolean isThreadWaiting(java.lang.Thread t)
           
static void sleep(long ms)
           
static void sleepUntil(long targetTimeMs)
           
static void startSimulating()
           
static void stopSimulating()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

LOG

public static Logger LOG
Constructor Detail

Time

public Time()
Method Detail

startSimulating

public static void startSimulating()

stopSimulating

public static void stopSimulating()

isSimulating

public static boolean isSimulating()

sleepUntil

public static void sleepUntil(long targetTimeMs)
                       throws java.lang.InterruptedException
Throws:
java.lang.InterruptedException

sleep

public static void sleep(long ms)
                  throws java.lang.InterruptedException
Throws:
java.lang.InterruptedException

currentTimeMillis

public static long currentTimeMillis()

currentTimeSecs

public static int currentTimeSecs()

advanceTime

public static void advanceTime(long ms)

isThreadWaiting

public static boolean isThreadWaiting(java.lang.Thread t)