Module file.worker

Class Unzipper

java.lang.Object
io.github.astrapi69.file.zip.Unzipper

public class Unzipper extends Object
The class Unzipper
  • Constructor Details

    • Unzipper

      public Unzipper()
    • Unzipper

      public Unzipper(File toDir, ZipFile zipFile)
    • Unzipper

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

    • builder

      public static Unzipper.UnzipperBuilder builder()
    • extractZipEntry

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

      public File getToDir()
    • setToDir

      public void setToDir(File toDir)
    • getZipFile

      public ZipFile getZipFile()
    • setZipFile

      public void setZipFile(ZipFile zipFile)
    • toBuilder

      public Unzipper.UnzipperBuilder toBuilder()
    • toString

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

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

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