Skip to main content

Module compression

Module compression 

Source
Expand description

Implementation of chunked-compression library in Rust. Archives can be created by making a new ChunkedArchive and serializing/writing it. An archive’s header can be verified and seek table decoded using decode_archive.

Structs§

ChunkInfo
Validated chunk information from an archive. Compressed ranges are relative to the start of compressed data (i.e. they start after the header and seek table).
ChunkedArchive
In-memory representation of a compressed chunked archive.
ChunkedDecompressor
Streaming decompressor for chunked archives. Example:
CompressedChunk
In-memory representation of a compressed chunk.
DecodedArchive
Validated information from decoding an archive.

Enums§

ChunkedArchiveError
Validated chunk information from an archive. Compressed ranges are relative to the start of compressed data (i.e. they start after the header and seek table).
ChunkedArchiveOptions
Options for constructing a chunked archive.
CompressionAlgorithm
The compression algorithm used to compress the chunks.
Compressor
A compressor that is capable of compressing chunks of a chunked-compression archive.
Decompressor
A decompressor that is capable of decompressing chunks of a compressed archive.
ThreadLocalCompressor
A compressor that uses thread-local storage to avoid reallocation of large state objects.
ThreadLocalDecompressor
A decompressor that uses thread-local storage to avoid reallocation of large state objects.

Functions§

decode_archive
Decodes a chunked archive header. Returns a DecodedArchive and any remaining bytes that are part of the chunk data. Returns Ok(None) if data is not large enough to decode the archive header & seek table.