Package net.lingala.zip4j.core
Class HeaderReader
- java.lang.Object
-
- net.lingala.zip4j.core.HeaderReader
-
public class HeaderReader extends Object
Helper class to read header information for the zip file
-
-
Constructor Summary
Constructors Constructor Description HeaderReader(RandomAccessFile zip4jRaf)
Creates a new HeaderReader object with the given input stream
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ZipModel
readAllHeaders()
Reads all the header information for the zip file.ZipModel
readAllHeaders(String fileNameCharset)
Reads all the header information for the zip file.LocalFileHeader
readLocalFileHeader(FileHeader fileHeader)
Reads local file header for the given file header
-
-
-
Constructor Detail
-
HeaderReader
public HeaderReader(RandomAccessFile zip4jRaf)
Creates a new HeaderReader object with the given input stream- Parameters:
zip4jRaf
-
-
-
Method Detail
-
readAllHeaders
public ZipModel readAllHeaders() throws ZipException
Reads all the header information for the zip file.
Note: This method does not read local file header information- Returns:
ZipModel
- Throws:
ZipException
-
readAllHeaders
public ZipModel readAllHeaders(String fileNameCharset) throws ZipException
Reads all the header information for the zip file. File names are read with input charset name. If this parameter is null, default system charset is used.
Note: This method does not read local file header information- Returns:
ZipModel
- Throws:
ZipException
-
readLocalFileHeader
public LocalFileHeader readLocalFileHeader(FileHeader fileHeader) throws ZipException
Reads local file header for the given file header- Parameters:
fileHeader
-- Returns:
LocalFileHeader
- Throws:
ZipException
-
-