8038653: Fix Time.toLocalTime, Time.valueOf javadoc clarification
authorlancea
Wed, 02 Apr 2014 10:20:14 -0400
changeset 23707 4580f737d5b9
parent 23706 5ea287e13cdb
child 23708 fea03b9ae8af
8038653: Fix Time.toLocalTime, Time.valueOf javadoc clarification Reviewed-by: alanb
jdk/src/share/classes/java/sql/Time.java
--- a/jdk/src/share/classes/java/sql/Time.java	Wed Apr 02 14:57:17 2014 +0200
+++ b/jdk/src/share/classes/java/sql/Time.java	Wed Apr 02 10:20:14 2014 -0400
@@ -253,7 +253,8 @@
     /**
      * Obtains an instance of {@code Time} from a {@link LocalTime} object
      * with the same hour, minute and second time value as the given
-     * {@code LocalTime}.
+     * {@code LocalTime}. The nanosecond field from {@code LocalTime} is
+     * not part of the newly created {@code Time} object.
      *
      * @param time a {@code LocalTime} to convert
      * @return a {@code Time} object
@@ -269,7 +270,8 @@
      * Converts this {@code Time} object to a {@code LocalTime}.
      * <p>
      * The conversion creates a {@code LocalTime} that represents the same
-     * hour, minute, and second time value as this {@code Time}.
+     * hour, minute, and second time value as this {@code Time}. The
+     * nanosecond {@code LocalTime} field will be set to zero.
      *
      * @return a {@code LocalTime} object representing the same time value
      * @since 1.8