FileDocCategorySizeDatePackage
FileDeflater.javaAPI DocExample668Sun Mar 28 19:07:12 BST 1999None

FileDeflater

public class FileDeflater extends Object

Fields Summary
public static final String
DEFLATE_SUFFIX
Constructors Summary
Methods Summary
public static voidmain(java.lang.String[] args)


       

    for (int i = 0; i < args.length; i++) {
      try {
        FileInputStream fin = new FileInputStream(args[i]);      
        FileOutputStream fout = new FileOutputStream(args[i] + DEFLATE_SUFFIX);
        DeflaterOutputStream dos = new DeflaterOutputStream(fout);
        StreamCopier.copy(fin, dos);
        dos.close();
        fin.close();
      }
      catch (IOException e) {
        System.err.println(e);     
      }
    }