Struct MultiBzDecoder

pub struct MultiBzDecoder<R>(/* private field */);

A bzip2 streaming decoder that decodes all members of a multistream.

Wikipedia, particularly, uses bzip2 multistream for their dumps, and the pbzip2 tool creates such data as well.

Implementations

impl<R> MultiBzDecoder<R>

fn get_ref(&self) -> &R

Acquires a reference to the underlying reader.

fn get_mut(&mut self) -> &mut R

Acquires a mutable reference to the underlying stream.

Note that mutation of the stream may result in surprising results if this encoder is continued to be used.

fn into_inner(self) -> R

Consumes this decoder, returning the underlying reader.

impl<R: BufRead> MultiBzDecoder<R>

fn new(r: R) -> Self

Creates a new decoder from the given reader. If the bzip2 stream contains multiple members all will be decoded.

Trait Implementations

impl<R: BufRead + Write> Write for MultiBzDecoder<R>

fn write(&mut self, buf: &[u8]) -> Result<usize>
fn flush(&mut self) -> Result<()>

impl<R: BufRead> Read for MultiBzDecoder<R>

fn read(&mut self, into: &mut [u8]) -> Result<usize>

Auto Trait Implementations

impl<R> Freeze for MultiBzDecoder<R> where BzDecoder<R>: Freeze,

impl<R> RefUnwindSafe for MultiBzDecoder<R> where BzDecoder<R>: RefUnwindSafe,

impl<R> Send for MultiBzDecoder<R> where BzDecoder<R>: Send,

impl<R> Sync for MultiBzDecoder<R> where BzDecoder<R>: Sync,

impl<R> Unpin for MultiBzDecoder<R> where BzDecoder<R>: Unpin,

impl<R> UnsafeUnpin for MultiBzDecoder<R> where BzDecoder<R>: UnsafeUnpin,

impl<R> UnwindSafe for MultiBzDecoder<R> where BzDecoder<R>: UnwindSafe,

Blanket Implementations

impl<T> Any for MultiBzDecoder<R> where T: 'static + ?Sized,

fn type_id(&self) -> TypeId

impl<T> Borrow<T> for MultiBzDecoder<R> where T: ?Sized,

fn borrow(&self) -> &T

impl<T> BorrowMut<T> for MultiBzDecoder<R> where T: ?Sized,

fn borrow_mut(&mut self) -> &mut T

impl<T> From<T> for MultiBzDecoder<R>

fn from(t: T) -> T

Returns the argument unchanged.

impl<T, U> Into<U> for MultiBzDecoder<R> where U: From<T>,

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom<U> for MultiBzDecoder<R> where U: Into<T>,

type Error = never;
fn try_from(value: U) -> Result<T, never>

impl<T, U> TryInto<U> for MultiBzDecoder<R> where U: TryFrom<T>,

type Error = <U as TryFrom<T>>::Error;
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>