Package google.registry.util
Interface Clock
-
- All Superinterfaces:
java.io.Serializable
- All Known Implementing Classes:
SystemClock
@ThreadSafe public interface Clock extends java.io.Serializable
A clock that tells the current time in milliseconds or nanoseconds.Clocks are technically serializable because they are either a stateless wrapper around the system clock, or for testing, are just a wrapper around a DateTime. This means that if you serialize a clock and deserialize it elsewhere, you won't necessarily get the same time or time zone -- what you will get is a functioning clock.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.joda.time.DateTime
nowUtc()
Returns current time in UTC timezone.
-