Skip to main content

Decompressible

Trait Decompressible 

Source
pub trait Decompressible {
    // Required method
    fn decompress(&self) -> Result<Vec<u8>>;
}
Expand description

Internal trait to implement decompression over a data type.

See also Compressible for the reverse operation.

Required Methods§

Source

fn decompress(&self) -> Result<Vec<u8>>

This function decompress the provided data, returning the decompressed data, or an error if the decompression failed.

Compression format is auto-detected using each format’s magic numbers. See CompressionFormat for details on the supported formats.

§Returns

A Vec<u8> containing the decompressed data, or an error if decompression failed.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl Decompressible for &[u8]

Implementors§