public abstract class AbstractUnsupportedCompressionMethod extends Object implements ZipEntryCompressionMethod
| Constructor and Description |
|---|
AbstractUnsupportedCompressionMethod() |
| Modifier and Type | Method and Description |
|---|---|
InputStream |
createInputStream(InputStream is,
long compressedSize,
long uncompressedSize)
This method always throws an
UnsupportedCompressionMethodException. |
OutputStream |
createOutputStream(OutputStream os)
This method always throws an
UnsupportedCompressionMethodException. |
org.entityfs.RandomAccess |
createRandomAccess(org.entityfs.RandomAccess ra,
long compressedSize,
long uncompressedSize)
This method always throws an
UnsupportedCompressionMethodException. |
ZipEntryCompressionMethod |
createWithCompressionLevel(CompressionLevel level)
Create a new
ZipEntryCompressionMethod object that will have the
supplied compression level. |
boolean |
isRandomAccessSupported()
This method always returns
false |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetCode, getName, getVersionNeededToExtractpublic AbstractUnsupportedCompressionMethod()
public final InputStream createInputStream(InputStream is, long compressedSize, long uncompressedSize) throws UnsupportedCompressionMethodException
UnsupportedCompressionMethodException.createInputStream in interface ZipEntryCompressionMethodis - An open InputStream on the compressed file data.compressedSize - The total size of the compressed data.uncompressedSize - The total size of the uncompressed data.InputStream containing uncompressed file data.UnsupportedCompressionMethodException - Always.public final OutputStream createOutputStream(OutputStream os) throws UnsupportedCompressionMethodException
UnsupportedCompressionMethodException.createOutputStream in interface ZipEntryCompressionMethodos - The wrapped output stream.UnsupportedCompressionMethodException - Always.public final org.entityfs.RandomAccess createRandomAccess(org.entityfs.RandomAccess ra,
long compressedSize,
long uncompressedSize)
throws UnsupportedCompressionMethodException
UnsupportedCompressionMethodException.createRandomAccess in interface ZipEntryCompressionMethodra - An open random access object on the file entry's data.compressedSize - The total size of the compressed data.uncompressedSize - The total size of the uncompressed data.RandomAccess that can be used to read
uncompressed data.UnsupportedCompressionMethodException - Always.public final boolean isRandomAccessSupported()
falseisRandomAccessSupported in interface ZipEntryCompressionMethodfalse, always.public final ZipEntryCompressionMethod createWithCompressionLevel(CompressionLevel level)
ZipEntryCompressionMethodZipEntryCompressionMethod object that will have the
supplied compression level.
The reason for this method is that it makes it easier to set a custom compression level for a compression method, without having to create a new compression method object from scratch manually.
createWithCompressionLevel in interface ZipEntryCompressionMethodlevel - The compression level.this