FileCopy v.02
-------------

What is it?
----------

FileCopy is a utility for copying defective files.  FileCopy will attemt to
read any available byte in a file, and fill in a given byte for all
unreadable bytes.


Why on earth would i need such a utility?
----------------------------------------
The reason it was written was that I had a very large file on a CD, with a
read error about 5% into the file.  As I couldn't find anything to read
more than the first 5% i wrote this utility.

* ZIP-files should be able to succesfully decompress the unaffected files.
* Sound files can be played, with quiet passages at the affected areas.
* Text can be extracted from unaffected areas of a damaged file.


What does this nice little thing require?
----------------------------------------
Java 1.0 runtime installed, as far as i can tell. Nothing more.


How do I use it.
---------------
For all platforms the usage should be:

java filecopy [-skip <bytes>] [-byte <value>] [-q] [-qq] InputFile OutputFile

-skip <bytes> Defines how many bytes should be skipped if a read error occurs.
-byte <value> Defines the value to be inserted where the read error occurs.
-q            Quiet. Does not show pregress indicator.
-qq           Extra Quiet. Does not show pregress indicator or errors.
-h            Displays help information.
InputFile     The filename of the file to be read.
OutputFile    The filename to write the result to.

Example:

java filecopy -skip 512 -byte 32 a:\exampaper.txt exampaper2.txt

This will attempt to copy 'a:\exampaper.txt' to 'exampaper2.txt'.  If a
read fails, the program will skip 512 bytes, and make an attempt reading
that byte.  If it fails it'll write 512 spaces (byte 32) to
'exampaper2.txt'.  If it succeds it will attemt to read all 512 bytes
individually, and only replace the defective bytes.

When reading files, there is shown a '#' for each succesfully read kilobyte.
When reading bytes inside a skipped area, there will be a '+' or '-'
indicating wether or not the byte could be read.

- Some runtime environments have other names for 'java', try 'jre' or 'jview'.
- OS/2 users have a 'filecopy.cmd' included that accepts the same paramters.
- Windows users have a 'filecopy.bat' included that accepts the same paramters.


I'm not quite sure I got the idea of the '-skip' parameter.
----------------------------------------------------------
The -skip parameter defines how many bytes should be skipped after a read
failure.  If the byte after the skip is okay, the program attempts to read
all the bytes inside the skipped area. If not, it'll perform another jump.

Values below 1024 are good.  1 will be quite slow if there are many errors.
In general I'll recommend 64 or 128 as values.


Future plans?
------------
None, unless requested.


Source?
------
Is included, and may be used for any purpose you'd like.  I take no
responsebility however!


No responsebility?
-----------------
No, I take no responsebility for any consequences the use of this program
may have - unless they're good ones of course.


How can I pay you?
-----------------
You don't have to.  Send an email, if you've salvaged that precious file
you thought you'd lost forever.


How do I then send an email?
---------------------------
Mail me at 'sh0dan@voxpod.dk'

You can also find some nice realtime multimedia demo's at http://voxpod.dk
- that should be a lesson to all who think Java is slow!


What's your real name then?
--------------------------
Klaus Post, if you're interested!


Is this the end?
---------------
Yes.
