public static class MonotonicClock.SystemClock extends MonotonicClock.AbstractEpochSamplingClock
MonotonicClock.AbstractEpochSamplingClock.AlmostSameTime
MonotonicClock.AbstractEpochSamplingClock, MonotonicClock.Global, MonotonicClock.SampledClock, MonotonicClock.SystemClock
Modifier and Type | Method and Description |
---|---|
long |
error() |
boolean |
isAfter(long instant) |
boolean |
isAfter(long now,
long instant) |
long |
now() |
pauseEpochSampling, resumeEpochSampling, translate
public long now()
Provides a monotonic time that can be compared with any other such value produced by the same clock
since the application started only; these times cannot be persisted or serialized to other nodes.
Nanosecond precision.
public long error()
public boolean isAfter(long instant)
public boolean isAfter(long now, long instant)
Copyright © 2009-2022 The Apache Software Foundation