java.lang.Object
com.pnfsoftware.jeb.util.encoding.zip.Zips

public class Zips extends Object
Zip compression utility methods.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static void
    zipBytes(File zipfile, String entryName, byte[] data)
    Create or overwrite a zip archive; add the specified entry to that archive.
    static void
    zipBytes(File zipfile, String entryName, byte[] data, int offset, int length)
    Create or overwrite a zip archive; add the specified entry to that archive.
    static void
    zipFile(File zipfile, File inputFile)
    Create or overwrite a zip archive; add the specified input file to that archive.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Zips

      public Zips()
  • Method Details

    • zipFile

      public static void zipFile(File zipfile, File inputFile) throws IOException
      Create or overwrite a zip archive; add the specified input file to that archive. The input file will be added to archive root.
      Parameters:
      zipfile - zip output file
      inputFile - input file
      Throws:
      IOException
    • zipBytes

      public static void zipBytes(File zipfile, String entryName, byte[] data) throws IOException
      Create or overwrite a zip archive; add the specified entry to that archive.
      Parameters:
      zipfile -
      entryName -
      data -
      Throws:
      IOException
    • zipBytes

      public static void zipBytes(File zipfile, String entryName, byte[] data, int offset, int length) throws IOException
      Create or overwrite a zip archive; add the specified entry to that archive.
      Parameters:
      zipfile -
      entryName -
      data -
      offset -
      length -
      Throws:
      IOException