aspose file tools
The moose likes Java in General and the fly likes Detect new file in a directory Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Java in General
Reply Bookmark "Detect new file in a directory" Watch "Detect new file in a directory" New topic
Author

Detect new file in a directory

Roy Cantos
Ranch Hand

Joined: Feb 22, 2002
Posts: 38
Hi Guys,
Is there a way that java can detect a new file, or existing API that we can use.

Thanks,
Roy
Anonymous
Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
The way I do this, is to start a thread that runs over all files in the folder from time to time.
This way you can track which files were deleted and which ones are new.
Hope this helps.
Regards,
G�nther.
http://www.javacoding.net
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Detect new file in a directory
 
Similar Threads
java redirection
Checking for EOF
Detect new file in a directory
Detecting EOF?
getting a filename