| Constructor and Description |
|---|
ManualClock()
Create a new instance.
|
ManualClock(long wallInit,
long monotonicInit)
Create a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
long |
monotonicTime()
Current time from a monotonic clock source.
|
void |
setMonotonicTime(long t)
Set the monotonic time to the value
t. |
void |
setWallTime(long t)
Set the wall time to the value
t. |
long |
wallTime()
Current wall time in milliseconds since the epoch.
|
public ManualClock()
public ManualClock(long wallInit,
long monotonicInit)
wallInit - Initial value for the wall time.monotonicInit - Initial value for the monotonic time.public long wallTime()
Clockpublic long monotonicTime()
ClockmonotonicTime in interface Clockpublic void setWallTime(long t)
t.public void setMonotonicTime(long t)
t.