[][src]Struct lzzzz::lz4f::ReadDecompressor

pub struct ReadDecompressor<'a, R: Read> { /* fields omitted */ }

The Read-based streaming decompressor.

Example

use lzzzz::lz4f::ReadDecompressor;
use std::{fs::File, io::prelude::*};

let mut f = File::open("foo.lz4")?;
let mut r = ReadDecompressor::new(&mut f)?;

let mut buf = Vec::new();
r.read_to_end(&mut buf)?;

Implementations

impl<'a, R: Read> ReadDecompressor<'a, R>[src]

pub fn new(reader: R) -> Result<Self>[src]

Creates a new ReadDecompressor<R>.

pub fn set_dict<D>(&mut self, dict: D) where
    D: Into<Cow<'a, [u8]>>, 
[src]

Sets the dictionary.

pub fn read_frame_info(&mut self) -> Result<FrameInfo>[src]

Reads the frame header and returns FrameInfo.

Calling this function before any Read operations does not consume the frame body.

Trait Implementations

impl<R: Read, '_> Read for ReadDecompressor<'_, R>[src]

Auto Trait Implementations

impl<'a, R> RefUnwindSafe for ReadDecompressor<'a, R> where
    R: RefUnwindSafe

impl<'a, R> Send for ReadDecompressor<'a, R> where
    R: Send

impl<'a, R> !Sync for ReadDecompressor<'a, R>

impl<'a, R> Unpin for ReadDecompressor<'a, R> where
    R: Unpin

impl<'a, R> UnwindSafe for ReadDecompressor<'a, R> where
    R: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.