public interface Clock
SYSTEM
implementation
that calls the builtin java methods is probably the right one to use. Other implementations
would typically only get used for unit tests or other cases where precise control of the clock
is needed.Modifier and Type | Field and Description |
---|---|
static Clock |
SYSTEM
Default clock implementation based on corresponding calls in
System . |
Modifier and Type | Method and Description |
---|---|
long |
monotonicTime()
Current time from a monotonic clock source.
|
long |
wallTime()
Current wall time in milliseconds since the epoch.
|
long wallTime()
long monotonicTime()