|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.jackrabbit.mk.util.AscendingClock
public class AscendingClock
A clock that normally returns the current system time since 1970, and is guaranteed to return ascending values. It returns ascending values even if the system time is changed, and never the same value twice. Worst case, it returns incrementing values. Unique nanosecond values are returned for system times between the years 1970 and 2554.
| Constructor Summary | |
|---|---|
AscendingClock(long lastMillis)
Create a new clock. |
|
| Method Summary | |
|---|---|
long |
nanoTime()
Get the current time, ensuring that the value is always larger than the last returned time, even if the system time was changed. |
long |
time()
Get the current time, ensuring that the value is always larger than the last returned time, even if the system time was changed. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AscendingClock(long lastMillis)
lastMillis - the time (the next returned value will be at least one
bigger)| Method Detail |
|---|
public long nanoTime()
public long time()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||