This aims to be a complete implementation of XZ data compression in pure Java. Features:
- Full support for the .xz file format specification version 1.0.4
- Single-threaded streamed compression and decompression
- Single-threaded decompression with limited random access support
- Raw streams (no .xz headers) for advanced users, including LZMA2 with preset dictionary
Threading is planned but it is unknown when it will be implemented.
For the latest source code, see the home page of XZ for Java.
XZ for Java has been put into the public domain, thus you can do whatever you want with it. All the files in the package have been written by Lasse Collin, Igor Pavlov, and/or Brett Okken.
This software is provided "as is", without any warranty.
Class Summary Class Description ARMOptionsBCJ filter for little endian ARM instructions. ARMThumbOptionsBCJ filter for little endian ARM-Thumb instructions. ArrayCacheCaches large arrays for reuse (base class and a dummy cache implementation). BasicArrayCacheA basic
DeltaInputStreamDecodes raw Delta-filtered data (no XZ headers). DeltaOptionsDelta filter options. FilterOptionsBase class for filter-specific options classes. FinishableOutputStreamOutput stream that supports finishing without closing the underlying stream. FinishableWrapperOutputStreamWraps an output stream to a finishable output stream for use with raw encoders. IA64OptionsBCJ filter for Itanium (IA-64) instructions. LZMA2InputStreamDecompresses a raw LZMA2 stream (no XZ headers). LZMA2OptionsLZMA2 compression options. LZMAInputStreamDecompresses legacy .lzma files and raw LZMA streams (no .lzma header). LZMAOutputStreamCompresses into the legacy .lzma file format or into a raw LZMA stream. PowerPCOptionsBCJ filter for big endian PowerPC instructions. ResettableArrayCacheAn ArrayCache wrapper that remembers what has been allocated and allows returning all allocations to the underlying cache at once. SeekableFileInputStreamWraps a
RandomAccessFilein a SeekableInputStream.
SeekableInputStreamInput stream with random access support. SeekableXZInputStreamDecompresses a .xz file in random access mode. SingleXZInputStreamDecompresses exactly one XZ Stream in streamed mode (no seeking). SPARCOptionsBCJ filter for SPARC. X86OptionsBCJ filter for x86 (32-bit and 64-bit) instructions. XZXZ constants. XZInputStreamDecompresses a .xz file in streamed mode (no seeking). XZOutputStreamCompresses into the .xz file format.
Exception Summary Exception Description CorruptedInputExceptionThrown when the compressed input data is corrupt. MemoryLimitExceptionThrown when the memory usage limit given to the XZ decompressor would be exceeded. UnsupportedOptionsExceptionThrown when compression options not supported by this implementation are detected. XZFormatExceptionThrown when the input data is not in the XZ format. XZIOExceptionGeneric
IOExceptionspecific to this package.