Class Unzipper


  • public class Unzipper
    extends java.lang.Object
    The class Unzipper
    • Constructor Detail

      • Unzipper

        public Unzipper()
      • Unzipper

        public Unzipper​(java.io.File toDir,
                        java.util.zip.ZipFile zipFile)
      • Unzipper

        public Unzipper​(java.util.zip.ZipFile zipFile,
                        java.io.File toDir)
        Instantiates a new unzipper.
        Parameters:
        zipFile - the zip file
        toDir - the to dir
    • Method Detail

      • extractZipEntry

        public void extractZipEntry​(java.util.zip.ZipFile zipFile,
                                    java.util.zip.ZipEntry target,
                                    java.io.File toDirectory)
                             throws java.io.IOException
        Extract zip entry.
        Parameters:
        zipFile - the zip file
        target - the target
        toDirectory - the to directory
        Throws:
        java.io.IOException - Signals that an I/O exception has occurred.
      • getToDir

        public java.io.File getToDir()
      • setToDir

        public void setToDir​(java.io.File toDir)
      • getZipFile

        public java.util.zip.ZipFile getZipFile()
      • setZipFile

        public void setZipFile​(java.util.zip.ZipFile zipFile)
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • unzip

        public void unzip()
                   throws java.io.IOException
        Unzip.
        Throws:
        java.io.IOException - Signals that an I/O exception has occurred.
      • unzip

        public void unzip​(java.util.zip.ZipFile zipFile,
                          java.io.File toDir)
                   throws java.io.IOException
        Unzip.
        Parameters:
        zipFile - the zip file
        toDir - the to dir
        Throws:
        java.io.IOException - Signals that an I/O exception has occurred.