001/*
002 * Copyright (c) 1999-2001 Keiron Liddle, Aftex Software
003 *
004 * This library is free software; you can redistribute it and/or
005 * modify it under the terms of the GNU Lesser General Public
006 * License as published by the Free Software Foundation; either
007 * version 2.1 of the License, or (at your option) any later version.
008 *
009 * This library is distributed in the hope that it will be useful,
010 * but WITHOUT ANY WARRANTY; without even the implied warranty of
011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
012 * Lesser General Public License for more details.
013 *
014*/
015package com.aftexsw.util.bzip;
016
017import java.io.*;
018
019class ZipThread extends Thread {
020        File in;
021        File out;
022        int block;
023        BZipProgress guiProg;
024
025        ZipThread(File i, File o, int b) {
026                guiProg = new BZipProgress(i.length(), "zipping file " + i);
027                in = i;
028                out = o;
029                block = b;
030        }
031
032        public void run() {
033                BZip.compress(in, out, block, guiProg/*BZip.dummyProg*/);
034                guiProg.dispose();
035        }
036}