java.lang.Object |
↳ |
com.pnfsoftware.jeb.util.encoding.zip.fsr.ZipFailSafeReader |
Class Overview
PNF Software's Zip Fail Safe Reader (PZFSR). This parser attempts to handle corner-cases that
fail Oracle's and Apache Common's parsers.
Limitations:
- limited to 2Gb archives at most
- zip64 is not supported
- uncommon flags are not supported
- non-standard attributes are disregarded
- the only compression scheme supported is DEFLATE
Summary
Public Constructors |
|
ZipFailSafeReader(File file)
Construct with all optional settings set to false.
|
|
ZipFailSafeReader(SeekableByteChannel channel)
Construct with all optional settings set to false.
|
|
ZipFailSafeReader(File file, boolean treatUnsupportedCompressionAsDeflate, boolean ignoreEncryption, boolean recoveryMode)
|
|
ZipFailSafeReader(SeekableByteChannel channel, boolean treatUnsupportedCompressionAsDeflate, boolean ignoreEncryption, boolean recoveryMode)
|
[Expand]
Inherited Methods |
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
final
void
|
wait()
|
|
From interface
java.lang.AutoCloseable
|
Public Constructors
public
ZipFailSafeReader
(File file)
Construct with all optional settings set to false.
public
ZipFailSafeReader
(SeekableByteChannel channel)
Construct with all optional settings set to false.
public
ZipFailSafeReader
(File file, boolean treatUnsupportedCompressionAsDeflate, boolean ignoreEncryption, boolean recoveryMode)
Parameters
file |
input zip |
treatUnsupportedCompressionAsDeflate |
optional |
ignoreEncryption |
optional |
recoveryMode |
optional; if true, the reader will attempt to recover zip entries of
truncated files, including those with incomplete Central Directory |
public
ZipFailSafeReader
(SeekableByteChannel channel, boolean treatUnsupportedCompressionAsDeflate, boolean ignoreEncryption, boolean recoveryMode)
Parameters
channel |
input |
recoveryMode |
optional; if true, the reader will attempt to recover zip entries of
truncated files, including those with incomplete Central Directory |
Public Methods
public
ZipEntry
getEntry
(String filename)
public
int
getNumberOfEntries
()
public
int
getOffsetAppendedData
()
public
int
getOffsetFirstEntry
()
public
boolean
hasAppendedData
()
public
boolean
hasEntry
(String filename)
public
boolean
hasPrependedData
()
public
boolean
isClosed
()
public
boolean
isTruncated
()
public
ZipData
readData
(String filename)
public
String
toString
()