[go: up one dir, main page]

Struct zstd::block::Decompressor [] [src]

pub struct Decompressor {
    // some fields omitted
}

Allows to decompress independently multiple blocks of data.

This reduces memory usage compared to calling decompress multiple times.

Methods

impl Decompressor
[src]

Creates a new zstd decompressor.

Creates a new zstd decompressor, using the given dictionary.

Deompress a single block of data to the given destination buffer.

Returns the number of bytes written, or an error if something happened (for instance if the destination buffer was too small).

Decompress a block of data, and return the decompressed result in a Vec<u8>.

The decompressed data should be less than capacity bytes, or an error will be returned.

Trait Implementations

impl Default for Decompressor
[src]

Returns the "default value" for a type. Read more