File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Java in General and the fly likes File Delta Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "File Delta" Watch "File Delta" New topic

File Delta

Grant Crofton
Ranch Hand

Joined: Nov 08, 2000
Posts: 154
I'm trying to find a way of comparing two files, and finding out the differences between them - preferably without having the files to compare, so using some kind of checksum. This is in order to have a backup of a file, and when you back it up next, to only back up the parts of the file that have changed.
I think you'd need some hard maths to work this sort of thing out, but if anyone knows of a site with any information about it, I'd be grateful.
Carl Trusiak

Joined: Jun 13, 2000
Posts: 3340
No easy task. If your really serious on this, I suggest you check out diffutils from GNU. It will be a fairly large project but, you could port this from it's original c source to Java. Or, you could just create a gui front end to the exe in java.
Hope this helps and good luck

I Hope This Helps
Carl Trusiak, SCJP2, SCWCD
Grant Crofton
Ranch Hand

Joined: Nov 08, 2000
Posts: 154
Thanks, Carl, that looks like it will be useful.
You've been very helpful today.
Here, have five stars for helpfulness:
subject: File Delta