@ThreadSafe public interface Ticker
Modifier and Type | Method and Description |
---|---|
static Ticker |
disabledTicker()
Returns a ticker that always returns
0 . |
long |
read()
Returns the number of nanoseconds elapsed since this ticker's fixed point of reference.
|
static Ticker |
systemTicker()
Returns a ticker that reads the current time using
System.nanoTime() . |
long read()
@Nonnull static Ticker systemTicker()
System.nanoTime()
.System.nanoTime()