This is an automated email from the ASF dual-hosted git repository. ggregory pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/commons-io.git
The following commit(s) were added to refs/heads/master by this push: new ae9920e4f Javadoc new 2ca87c10c Merge branch 'master' of https://gitbox.apache.org/repos/asf/commons-io.git ae9920e4f is described below commit ae9920e4f81a631d67aa4ccb6d15806f694566f1 Author: Gary Gregory <garydgreg...@gmail.com> AuthorDate: Sat Mar 29 08:23:16 2025 -0400 Javadoc --- .../commons/io/file/attribute/FileTimes.java | 35 ++++++++++++++++------ 1 file changed, 26 insertions(+), 9 deletions(-) diff --git a/src/main/java/org/apache/commons/io/file/attribute/FileTimes.java b/src/main/java/org/apache/commons/io/file/attribute/FileTimes.java index bdd572a29..25a064b93 100644 --- a/src/main/java/org/apache/commons/io/file/attribute/FileTimes.java +++ b/src/main/java/org/apache/commons/io/file/attribute/FileTimes.java @@ -141,9 +141,13 @@ public static FileTime now() { /** * Converts NTFS time (100 nanosecond units since 1 January 1601) to Java time. + * <p> + * An NTFS file time is a 64-bit value for the number of 100-nanosecond intervals since 12:00 A.M. January 1, 1601 Coordinated Universal Time (UTC). + * </p> * - * @param ntfsTime the NTFS time in 100 nanosecond units - * @return the Date + * @param ntfsTime the NTFS time, 100-nanosecond units since 1 January 1601. + * @return the Date input. + * @see <a href="https://learn.microsoft.com/en-us/windows/win32/sysinfo/file-times">NTFS File Times</a> */ public static Date ntfsTimeToDate(final long ntfsTime) { final long javaHundredNanos = Math.addExact(ntfsTime, WINDOWS_EPOCH_OFFSET); @@ -153,10 +157,14 @@ public static Date ntfsTimeToDate(final long ntfsTime) { /** * Converts NTFS time (100-nanosecond units since 1 January 1601) to a FileTime. + * <p> + * An NTFS file time is a 64-bit value for the number of 100-nanosecond intervals since 12:00 A.M. January 1, 1601 Coordinated Universal Time (UTC). + * </p> * - * @param ntfsTime the NTFS time in 100-nanosecond units - * @return the FileTime + * @param ntfsTime the NTFS time, 100-nanosecond units since 1 January 1601. + * @return the FileTime input. * @see #toNtfsTime(FileTime) + * @see <a href="https://learn.microsoft.com/en-us/windows/win32/sysinfo/file-times">NTFS File Times</a> */ public static FileTime ntfsTimeToFileTime(final long ntfsTime) { final long javaHundredsNanos = Math.addExact(ntfsTime, WINDOWS_EPOCH_OFFSET); @@ -234,9 +242,12 @@ public static FileTime toFileTime(final Date date) { /** * Converts a {@link Date} to NTFS time. + * <p> + * An NTFS file time is a 64-bit value for the number of 100-nanosecond intervals since 12:00 A.M. January 1, 1601 Coordinated Universal Time (UTC). + * </p> * - * @param date the Date - * @return the NTFS time + * @param date the Date input. + * @return the NTFS time, 100-nanosecond units since 1 January 1601. */ public static long toNtfsTime(final Date date) { final long javaHundredNanos = date.getTime() * HUNDRED_NANOS_PER_MILLISECOND; @@ -245,9 +256,12 @@ public static long toNtfsTime(final Date date) { /** * Converts a {@link FileTime} to NTFS time (100-nanosecond units since 1 January 1601). + * <p> + * An NTFS file time is a 64-bit value for the number of 100-nanosecond intervals since 12:00 A.M. January 1, 1601 Coordinated Universal Time (UTC). + * </p> * - * @param fileTime the FileTime - * @return the NTFS time in 100-nanosecond units + * @param fileTime the FileTime input. + * @return the NTFS time, 100-nanosecond units since 1 January 1601. */ public static long toNtfsTime(final FileTime fileTime) { final Instant instant = fileTime.toInstant(); @@ -257,9 +271,12 @@ public static long toNtfsTime(final FileTime fileTime) { /** * Converts Java time (milliseconds since Epoch) to NTFS time. + * <p> + * An NTFS file time is a 64-bit value for the number of 100-nanosecond intervals since 12:00 A.M. January 1, 1601 Coordinated Universal Time (UTC). + * </p> * * @param javaTime the Java time - * @return the NTFS time + * @return the NTFS time, 100-nanosecond units since 1 January 1601. * @since 2.16.0 */ public static long toNtfsTime(final long javaTime) {