java解压zip rar文件实例
package com.tservice.mrn.common; import java.io.*; import java.util.Enumeration; import org.apache.tools.ant.Project; import org.apache.tools.ant.taskdefs.Expand; import org.apache.tools.zip.*; import com.github.junrar.Archive; import com.github.junrar.rarfile.FileHeader; public abstract class ZipUtils { private static final int BUFFEREDSIZE = 1024; /** * @SuppressWarnings({ "rawtypes", "resource" }) public static String * unzip(File zipFile, String unzipDir, String * zipFileName) throws IOException { ZipFile zf = new * ZipFile(zipFile); Enumeration enu = zf.entries(); * String result = "";