QArchive.ORG Main Page
Home | Blog | Terms of service | Sign in
All Vista Win Linux Mac
Related Products

FileTimes 1.9
Download Now
File Size: 591 Kb

FileTimes 1.9



Released:2008-09-23
License:Freeware
Publisher:Canadian Mind Produc ts
Language:English
Platform:Vista, Windows, Linux, MAC, Mobile
Requirements:Java 1.1+
Install:No Install Support
Downloads:1112
Recommend FileTimes Suggest to Friend

Publisher's Description:

FileTimes - Java class library to get/set file and directory times: Create/LastModified/LastAccessed. For Windows only.

Create time is when the file was first written. Modified

time (sometimes called lastModified) is when the file was

last written. Accessed time is when the file was last read

or written. Checking its date, looking at its attributes or

checking to see if it exists does not count as reading it.

Get/Set Windows File Times Create/LastAccessed/LastModified

with a JNI native code class.

Java and JNI you include in your own code.

You can test with

C:

CD \com.mindprod.filetimes

java com.mindprod.filetimes.FileTimes

and ensuring nativefiletimes.dll is on the path, e.g. in the

current directory. In JDK 1.5+ the DLL may be in the jar, so

long is it has no package path name.

See FileTimes.java for the API to use these methods in your

own programs. FileTimes does nothing by itself, other than a

debugging test harness to demonstrate the methods.

Windows keeps file timestamps accurate to 100 nanoseconds

with 10,000 times as much precision as Java's 1 ms. This

means if you copy a file in Java, the new file will not

have the exact same timestamp as the old. This package

retrieves and sets timestamps accurate only to the

millisecond.

List of Changes:

Version 1.9 from 2008-09-23

Show all changes

Version 1.8 from 2007-08-31

add TouchDirs, add three now time setting methods.

Screenshot:

Read and set Windows file/dir times from Java
 

Download Now
File Size: 591 Kb

Share |


Text link code :
Hyper link code:
UBB/BLOG code:

Latest User Reviews:

Wu M 2009-03-27 02:52:19 #
Version: 1.9

Works very nicely.

I had a bit of a problem because I was not aware that the name of the calling class is part of the call interface of a native method, so I cannot call the native methods from my own Java classes. That was my fault of course.

The main() method is apparently not flawless - doesn't matter, it's just the test harness after all.

It should be noted that there is a Windows registry setting to switch off setting the Accessed time. I understand on Vista this is set by default. This makes querying the Accessed time doubtful. This is not a problem of FileTimes of course.

To repeat what I said at the beginning: FileTimes works very nicely for me.



Mvipat1 2008-08-06 12:37:47 #
Version: 1.8

Awesome

The product worked like a charm but it needs more documentation.




Download Now
File Size: 591 Kb



Search