voldemort.utils
Class SystemTime

java.lang.Object
  extended by voldemort.utils.SystemTime
All Implemented Interfaces:
Time

public class SystemTime
extends java.lang.Object
implements Time

Time implementation that just reads from the system clock


Field Summary
static SystemTime INSTANCE
           
 
Fields inherited from interface voldemort.utils.Time
HOURS_PER_DAY, MS_PER_DAY, MS_PER_HOUR, MS_PER_SECOND, NS_PER_MS, NS_PER_SECOND, NS_PER_US, SECONDS_PER_DAY, SECONDS_PER_HOUR, US_PER_MS, US_PER_SECOND
 
Constructor Summary
SystemTime()
           
 
Method Summary
 java.util.Date getCurrentDate()
           
 long getMilliseconds()
           
 long getNanoseconds()
           
 int getSeconds()
           
 void sleep(long ms)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

INSTANCE

public static final SystemTime INSTANCE
Constructor Detail

SystemTime

public SystemTime()
Method Detail

getCurrentDate

public java.util.Date getCurrentDate()
Specified by:
getCurrentDate in interface Time

getMilliseconds

public long getMilliseconds()
Specified by:
getMilliseconds in interface Time

getNanoseconds

public long getNanoseconds()
Specified by:
getNanoseconds in interface Time

getSeconds

public int getSeconds()
Specified by:
getSeconds in interface Time

sleep

public void sleep(long ms)
           throws java.lang.InterruptedException
Specified by:
sleep in interface Time
Throws:
java.lang.InterruptedException


Jay Kreps, Roshan Sumbaly, Alex Feinberg, Bhupesh Bansal, Lei Gao, Chinmay Soman, Vinoth Chandar, Zhongjie Wu