pub trait Decompressor<B: ByteBuf> {
type Buf: ByteBuf;
// Required method
fn decompress<R, F>(buf: &mut B, f: F) -> Result<R>
where F: FnOnce(&mut Self::Buf) -> Result<R>;
}Expand description
A trait for record decompression algorithms.
Required Associated Types§
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementors§
Source§impl<B: ByteBuf> Decompressor<B> for Gzip
Available on crate feature gzip only.
impl<B: ByteBuf> Decompressor<B> for Gzip
Available on crate feature
gzip only.Source§impl<B: ByteBuf> Decompressor<B> for Lz4
Available on crate feature lz4 only.
impl<B: ByteBuf> Decompressor<B> for Lz4
Available on crate feature
lz4 only.Source§impl<B: ByteBuf> Decompressor<B> for Snappy
Available on crate feature snappy only.
impl<B: ByteBuf> Decompressor<B> for Snappy
Available on crate feature
snappy only.