| Modifier and Type | Field and Description |
|---|---|
| private final ArrayCache | |
| private long | |
| private IOException | |
| private final long | |
| private boolean | |
| private LZEncoder | |
| private LZMAEncoder | |
| private OutputStream | |
| private final int | |
| private final RangeEncoderToStream | |
| private final byte[] | |
| private final boolean |
| Access | Constructor and Description |
|---|---|
| private | LZMAOutputStream(OutputStream out, LZMA2Options options, boolean useHeader, boolean useEndMarker, long expectedUncompressedSize, ArrayCache arrayCache)
|
| public | LZMAOutputStream(OutputStream
output stream to which the compressed data
will be written out, LZMA2Options LZMA compression options; the same class
is used here as is for LZMA2 options, long uncompressed size of the data to be compressed;
use inputSize)-1 when unknownCreates a new compressor for the legacy .lzma file format. |
| public | LZMAOutputStream(OutputStream
output stream to which the compressed data
will be written out, LZMA2Options LZMA compression options; the same class
is used here as is for LZMA2 options, long uncompressed size of the data to be compressed;
use inputSize, ArrayCache -1 when unknowncache to be used for allocating large arrays arrayCache)Creates a new compressor for the legacy .lzma file format. |
| public | LZMAOutputStream(OutputStream
output stream to which the compressed data
will be written out, LZMA2Options LZMA compression options; the same class
is used here as is for LZMA2 options, boolean if end of stream marker should be written useEndMarker)Creates a new compressor for raw LZMA (also known as LZMA1) stream. |
| public | LZMAOutputStream(OutputStream
output stream to which the compressed data
will be written out, LZMA2Options LZMA compression options; the same class
is used here as is for LZMA2 options, boolean if end of stream marker should be written useEndMarker, ArrayCache cache to be used for allocating large arrays arrayCache)Creates a new compressor for raw LZMA (also known as LZMA1) stream. |
| Modifier and Type | Method and Description |
|---|---|
| public void | close()
Overrides java. Implements java. |
| public void | finish()
Overrides org. |
| public void | flush()
Overrides java. Implements java. |
| public int | |
| public long | |
| public void | write(int
the b)byte.Implements abstract java. |
| public void | write(byte[]
the data. buf, int the start offset in the data. off, int the number of bytes to write. len)Overrides java. len bytes from the specified byte array
starting at offset off to this output stream.
|
| arrayCache | back to summary |
|---|---|
| private final ArrayCache arrayCache | |
| currentUncompressedSize | back to summary |
|---|---|
| private long currentUncompressedSize | |
| exception | back to summary |
|---|---|
| private IOException exception | |
| expectedUncompressedSize | back to summary |
|---|---|
| private final long expectedUncompressedSize | |
| finished | back to summary |
|---|---|
| private boolean finished | |
| lz | back to summary |
|---|---|
| private LZEncoder lz | |
| lzma | back to summary |
|---|---|
| private LZMAEncoder lzma | |
| out | back to summary |
|---|---|
| private OutputStream out | |
| props | back to summary |
|---|---|
| private final int props | |
| rc | back to summary |
|---|---|
| private final RangeEncoderToStream rc | |
| tempBuf | back to summary |
|---|---|
| private final byte[] tempBuf | |
| useEndMarker | back to summary |
|---|---|
| private final boolean useEndMarker | |
| LZMAOutputStream | back to summary |
|---|---|
| private LZMAOutputStream(OutputStream out, LZMA2Options options, boolean useHeader, boolean useEndMarker, long expectedUncompressedSize, ArrayCache arrayCache) throws IOException | |
| LZMAOutputStream | back to summary |
|---|---|
| public LZMAOutputStream(OutputStream out, LZMA2Options options, long inputSize) throws IOException Creates a new compressor for the legacy .lzma file format. If the uncompressed size of the input data is known, it will be stored in the .lzma header and no end of stream marker will be used. Otherwise the header will indicate unknown uncompressed size and the end of stream marker will be used. Note that a preset dictionary cannot be used in .lzma files but it can be used for raw LZMA streams.
| |
| LZMAOutputStream | back to summary |
|---|---|
| public LZMAOutputStream(OutputStream out, LZMA2Options options, long inputSize, ArrayCache arrayCache) throws IOException Creates a new compressor for the legacy .lzma file format.
This is identical to
| |
| LZMAOutputStream | back to summary |
|---|---|
| public LZMAOutputStream(OutputStream out, LZMA2Options options, boolean useEndMarker) throws IOException Creates a new compressor for raw LZMA (also known as LZMA1) stream. Raw LZMA streams can be encoded with or without end of stream marker. When decompressing the stream, one must know if the end marker was used and tell it to the decompressor. If the end marker wasn't used, the decompressor will also need to know the uncompressed size.
| |
| LZMAOutputStream | back to summary |
|---|---|
| public LZMAOutputStream(OutputStream out, LZMA2Options options, boolean useEndMarker, ArrayCache arrayCache) throws IOException Creates a new compressor for raw LZMA (also known as LZMA1) stream.
This is identical to
| |
| close | back to summary |
|---|---|
| public void close() throws IOException Overrides java. Implements java. Finishes the stream and closes the underlying OutputStream.
| |
| finish | back to summary |
|---|---|
| public void finish() throws IOException Overrides org. Finishes the stream without closing the underlying OutputStream. | |
| flush | back to summary |
|---|---|
| public void flush() throws IOException Overrides java. Implements java. Flushing isn't supported and will throw XZIOException.
| |
| getProps | back to summary |
|---|---|
| public int getProps() Returns the LZMA lc/lp/pb properties encoded into a single byte. This might be useful when handling file formats other than .lzma that use the same encoding for the LZMA properties as .lzma does. | |
| getUncompressedSize | back to summary |
|---|---|
| public long getUncompressedSize() Gets the amount of uncompressed data written to the stream. This is useful when creating raw LZMA streams without the end of stream marker. | |
| write | back to summary |
|---|---|
| public void write(int b) throws IOException Implements abstract java. Doc from java. Writes the specified byte to this output stream. The general
contract for
| |
| write | back to summary |
|---|---|
| public void write(byte[] buf, int off, int len) throws IOException Overrides java. Doc from java. Writes
If
If
| |