Skip to content

std::compress::gzip

Status: experimental

gzip encoder / decoder (RFC 1952; flate2-backed).

API details and source

The implementation source contains the complete declarations and implementation notes. The table below lists canonical Gossamer call signatures; every item name links directly to its implementation file.

Item Canonical signature or declaration Description
Level type Level Compression level (0 store-only … 9 best); default is gzip(1)'s 6.
decode fn decode(data: Vec<u8>) -> Result<Vec<u8>, errors::Error> Decompresses a gzip-formatted payload.
encode fn encode(data: Vec<u8>, level: i64) -> Result<Vec<u8>, errors::Error> Compresses bytes at the supplied Level.