Class AbstractZipUnArchiver

java.lang.Object
org.codehaus.plexus.archiver.AbstractUnArchiver
org.codehaus.plexus.archiver.zip.AbstractZipUnArchiver
All Implemented Interfaces:
FinalizerEnabled, UnArchiver
Direct Known Subclasses:
ZipUnArchiver

public abstract class AbstractZipUnArchiver extends AbstractUnArchiver
Author:
Emmanuel Venisse
  • Constructor Details

    • AbstractZipUnArchiver

      public AbstractZipUnArchiver()
    • AbstractZipUnArchiver

      public AbstractZipUnArchiver(File sourceFile)
  • Method Details

    • setEncoding

      public void setEncoding(String encoding)
      Sets the encoding to assume for file names and comments.

      Set to native-encoding if you want your platform's native encoding, defaults to UTF8.

    • setMaxOutputSize

      public void setMaxOutputSize(long maxOutputSize)
      Set maximum allowed size of the produced output. It may be used as a protection against zip bombs.
      Parameters:
      maxOutputSize - max size of the produced output, in bytes. Must be greater than 0
      Throws:
      IllegalArgumentException - if specified output size is less or equal to 0
    • execute

      protected void execute() throws ArchiverException
      Specified by:
      execute in class AbstractUnArchiver
      Throws:
      ArchiverException
    • execute

      protected void execute(String path, File outputDirectory) throws ArchiverException
      Specified by:
      execute in class AbstractUnArchiver
      Throws:
      ArchiverException