RFR 8038653 Time.toLocalTime, Time.valueOf javadoc clarification
Lance Andersen
lance.andersen at oracle.com
Tue Apr 1 11:35:23 UTC 2014
HI all,
Looking for a reviewer for the following javadoc clarification when using java.sql.Time.toLocalTime/ValueOf.
Here is the webrev which has been had its ccc approved
ljanders-mac:sql ljanders$ hg diff
diff -r fab6896b880f src/share/classes/java/sql/Time.java
--- a/src/share/classes/java/sql/Time.java Fri Mar 28 18:03:40 2014 +0100
+++ b/src/share/classes/java/sql/Time.java Tue Apr 01 07:31:36 2014 -0400
@@ -254,6 +254,9 @@
* 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}.
+ * <p>
+ * <strong>Note:</strong>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 +272,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
ljanders-mac:sql ljanders$
Best,
Lance
Lance Andersen| Principal Member of Technical Staff | +1.781.442.2037
Oracle Java Engineering
1 Network Drive
Burlington, MA 01803
Lance.Andersen at oracle.com
More information about the core-libs-dev
mailing list