Package com.nuix.superutilities.misc
Class ZipHelper
- java.lang.Object
-
- com.nuix.superutilities.misc.ZipHelper
-
public class ZipHelper extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description ZipHelper()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static voidcompressDirectoryToSevenZipFile(java.lang.String directory, java.lang.String sevenZipFile)static voidcompressDirectoryToZipFile(java.lang.String directory, java.lang.String zipFile, int compressionLevel)Compresses the contents of the given directory (files and sub-directories) in to a Zip file.
-
-
-
Method Detail
-
compressDirectoryToSevenZipFile
public static void compressDirectoryToSevenZipFile(java.lang.String directory, java.lang.String sevenZipFile) throws java.io.IOException- Throws:
java.io.IOException
-
compressDirectoryToZipFile
public static void compressDirectoryToZipFile(java.lang.String directory, java.lang.String zipFile, int compressionLevel) throws java.io.IOException, java.io.FileNotFoundExceptionCompresses the contents of the given directory (files and sub-directories) in to a Zip file.- Parameters:
directory- The directory to archive into the Zip file.zipFile- Where to write the Zip file.compressionLevel- What level of compression to use between 0 and 9, with 0 being no compression and 9 being the most compression.- Throws:
java.io.IOException- Thrown if there are issues with IOjava.io.FileNotFoundException- Thrown if file is not found
-
-