jdk/src/java.base/share/classes/java/time/LocalTime.java
changeset 34388 ab5f741f776a
parent 33848 80c992df5d92
child 34828 bc3eacb42ab1
equal deleted inserted replaced
34387:92a5f8d50d1a 34388:ab5f741f776a
   352      * Then, the instant and offset are used to calculate the local time.
   352      * Then, the instant and offset are used to calculate the local time.
   353      *
   353      *
   354      * @param instant  the instant to create the time from, not null
   354      * @param instant  the instant to create the time from, not null
   355      * @param zone  the time-zone, which may be an offset, not null
   355      * @param zone  the time-zone, which may be an offset, not null
   356      * @return the local time, not null
   356      * @return the local time, not null
       
   357      * @since 9
   357      */
   358      */
   358      public static LocalTime ofInstant(Instant instant, ZoneId zone) {
   359      public static LocalTime ofInstant(Instant instant, ZoneId zone) {
   359          Objects.requireNonNull(instant, "instant");
   360          Objects.requireNonNull(instant, "instant");
   360          Objects.requireNonNull(zone, "zone");
   361          Objects.requireNonNull(zone, "zone");
   361          ZoneOffset offset = zone.getRules().getOffset(instant);
   362          ZoneOffset offset = zone.getRules().getOffset(instant);