OffsetTime.now

Obtains the current time from the system clock _in the default time-zone. !(p) This will query the {@link Clock#systemDefaultZone() system clock} _in the default time-zone to obtain the current time. The offset will be calculated from the time-zone _in the clock. !(p) Using this method will prevent the ability to use an alternate clock for testing because the clock is hard-coded.

@return the current time using the system clock and default time-zone, not null

  1. OffsetTime now()
    class OffsetTime
    static
    now
    ()
  2. OffsetTime now(ZoneId zone)
  3. OffsetTime now(Clock clock)

Meta