Class ZipFileUtil
- java.lang.Object
-
- com.almis.awe.tools.filemanager.utils.ZipFileUtil
-
public class ZipFileUtil extends Object
Zip file util class- Author:
- pvidal
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidunzip(String zipFilename, String destDirname)Unzips the specified zip file to the specified destination directory.static voidzip(String zipFilename, List<String> filenames)Creates/updates a zip file.
-
-
-
Method Detail
-
zip
public static void zip(String zipFilename, List<String> filenames) throws IOException
Creates/updates a zip file.- Parameters:
zipFilename- the name of the zip to createfilenames- list of filename to add to the zip- Throws:
IOException- IO exception
-
unzip
public static void unzip(String zipFilename, String destDirname) throws IOException
Unzips the specified zip file to the specified destination directory. Replaces any files in the destination, if they already exist.- Parameters:
zipFilename- the name of the zip file to extractdestDirname- the directory to unzip to- Throws:
IOException- IO exception
-
-