std::compress::zstd¶
Status: experimental
Zstandard encoder / decoder (RFC 8478; libzstd-vendored).
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 |
|---|---|---|
decode |
fn decode(data: Vec<u8>) -> Result<Vec<u8>, errors::Error> |
One-shot Zstandard decompress. |
encode |
fn encode(data: Vec<u8>) -> Result<Vec<u8>, errors::Error> |
One-shot Zstandard compress at the default level (3). |
encode_level |
fn encode_level(data: Vec<u8>, level: i64) -> Result<Vec<u8>, errors::Error> |
One-shot Zstandard compress at the supplied level (1 fastest -- 22 best). |