Package net.lingala.zip4j.core
Class HeaderWriter
- java.lang.Object
-
- net.lingala.zip4j.core.HeaderWriter
-
public class HeaderWriter extends Object
-
-
Constructor Summary
Constructors Constructor Description HeaderWriter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidfinalizeZipFile(ZipModel zipModel, OutputStream outputStream)Processes zip header data and writes this data to the zip filevoidfinalizeZipFileWithoutValidations(ZipModel zipModel, OutputStream outputStream)Processes zip header data and writes this data to the zip file without any validations.voidupdateLocalFileHeader(LocalFileHeader localFileHeader, long offset, int toUpdate, ZipModel zipModel, byte[] bytesToWrite, int noOfDisk, SplitOutputStream outputStream)intwriteExtendedLocalHeader(LocalFileHeader localFileHeader, OutputStream outputStream)intwriteLocalFileHeader(ZipModel zipModel, LocalFileHeader localFileHeader, OutputStream outputStream)
-
-
-
Method Detail
-
writeLocalFileHeader
public int writeLocalFileHeader(ZipModel zipModel, LocalFileHeader localFileHeader, OutputStream outputStream) throws ZipException
- Throws:
ZipException
-
writeExtendedLocalHeader
public int writeExtendedLocalHeader(LocalFileHeader localFileHeader, OutputStream outputStream) throws ZipException, IOException
- Throws:
ZipExceptionIOException
-
finalizeZipFile
public void finalizeZipFile(ZipModel zipModel, OutputStream outputStream) throws ZipException
Processes zip header data and writes this data to the zip file- Parameters:
zipModel-outputStream-- Throws:
ZipException
-
finalizeZipFileWithoutValidations
public void finalizeZipFileWithoutValidations(ZipModel zipModel, OutputStream outputStream) throws ZipException
Processes zip header data and writes this data to the zip file without any validations. This process is not intended to use for normal operations (adding, deleting, etc) of a zip file. This method is used when certain validations need to be skipped (ex: Merging split zip files, adding comment to a zip file, etc)- Parameters:
zipModel-outputStream-- Throws:
ZipException
-
updateLocalFileHeader
public void updateLocalFileHeader(LocalFileHeader localFileHeader, long offset, int toUpdate, ZipModel zipModel, byte[] bytesToWrite, int noOfDisk, SplitOutputStream outputStream) throws ZipException
- Throws:
ZipException
-
-