public class DefaultClock extends Object implements Clock
Constructor and Description |
---|
DefaultClock() |
DefaultClock(boolean enableThreadCpuTime) |
Modifier and Type | Method and Description |
---|---|
long |
currentTimeMillis() |
long |
nanoTime() |
long |
threadUserNanoTime(long threadId) |
public DefaultClock()
public DefaultClock(boolean enableThreadCpuTime)
public long currentTimeMillis()
currentTimeMillis
in interface Clock
System.currentTimeMillis()
public long nanoTime()
nanoTime
in interface Clock
System.nanoTime()
public long threadUserNanoTime(long threadId)
threadUserNanoTime
in interface Clock
ThreadMXBean.getThreadUserTime(long)