|
||||||||||
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |
See:
Description
Interface Summary | |
---|---|
Clock | Provides a timing mechanism for returning the current time in 100-nano second intervals since 00:00:00.00, 15 October 1582. |
Class Summary | |
---|---|
SystemClockImpl | SystemClockImpl provides a timing mechanism for returning the
current time in 100-nano second intervals since 00:00:00.00, 15 October 1582. |
ThreadClockImpl | Clock provides a timing mechanism for returning the current time in
100-nano second intervals since 00:00:00.00, 15 October 1582. |
Exception Summary | |
---|---|
OverClockedException | This exception is raised whenever the clock generates too many timestamps in a given system interval. |
This package contains the Clock interface and implementations for generating UUID timestamps. UUID timestamps are measured in 100-nano second intervals since the Gregorian changeover epoch (00:00:00.00, 15 October 1582.) Due to several factors relating to time precision and time resolution on Windows tm and in Java tm in general; the Clock interface is introduced to allow different or custom strategies in timestamp generation. The IETF (Internet Engineering Task Force) specification details some of these approaches. For more information see the RFC 4122: A Universally Unique IDentifier (UUID) URN Namespace.
Two provided implementation are:
SystemClockImpl
- uses System.currentTimeMillis() and an
artificial counter to allow up to 10,000 ticks per millisecond interval.
ThreadClockImpl
- time resolution on certain operating
systems may not be 1-millisecond intervals. Windows tm according
to some reports to have time resolution in the 1-ms to 54-ms range. Using a
thread to provide a clock that increments it's counter at 10-ms intervals is
one means of compensating for this. (Due to bug parade issue:
4500388 10-ms and not 1-ms intervals are used in this implementation.)
|
||||||||||
PREV PACKAGE NEXT PACKAGE | FRAMES NO FRAMES |