org.yenc
Class ydecode
java.lang.Object
|
+--org.yenc.ydecode
- public class ydecode
- extends java.lang.Object
Decodifies files passed as command line arguments. This class is just an
example of how org.yenc.YEncDecoder
works so it provides
minimal functionality.
The files passed as arguments must be, either a single-part archive or
all the parts that compose a multi-part archive.
- Author:
- Luis Parravicini
- See Also:
YEncDecoder
Method Summary |
static void |
main(java.lang.String[] args)
|
java.lang.String[] |
sortFiles(YEncDecoder decoder,
java.lang.String[] files)
Sample code on how to decode multipart files. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
ydecode
public ydecode()
sortFiles
public java.lang.String[] sortFiles(YEncDecoder decoder,
java.lang.String[] files)
throws java.io.IOException,
YEncException
- Sample code on how to decode multipart files. If more than one file is
present in the array
files
all of them are assumed to be
parts of the same archive.
What this method does is to scan each file and run some tests on the
part number, filename and beginning/ending offsets of each part and
then returns an array of the files in the order they should be read
to decompress the archive.
main
public static void main(java.lang.String[] args)
throws java.io.IOException,
java.io.FileNotFoundException,
YEncException