pub struct Decoder { /* private fields */ }
Expand description
An in-memory decoder for streams of data.
Implementations
sourceimpl Decoder
impl Decoder
sourcepub fn with_dictionary(dictionary: &[u8]) -> Result<Self>
pub fn with_dictionary(dictionary: &[u8]) -> Result<Self>
Creates a new decoder initialized with the given dictionary.
sourcepub fn with_prepared_dictionary(
dictionary: &DecoderDictionary<'_>
) -> Result<Self>
pub fn with_prepared_dictionary(
dictionary: &DecoderDictionary<'_>
) -> Result<Self>
Creates a new decoder, using an existing DecoderDictionary
.
sourcepub fn set_parameter(&mut self, parameter: DParameter) -> Result<()>
pub fn set_parameter(&mut self, parameter: DParameter) -> Result<()>
Sets a decompression parameter for this decoder.
Trait Implementations
sourceimpl Operation for Decoder
impl Operation for Decoder
sourcefn run(
&mut self,
input: &mut InBuffer<'_>,
output: &mut OutBuffer<'_>
) -> Result<usize>
fn run(
&mut self,
input: &mut InBuffer<'_>,
output: &mut OutBuffer<'_>
) -> Result<usize>
Performs a single step of this operation. Read more
sourcefn finish(
&mut self,
_output: &mut OutBuffer<'_>,
finished_frame: bool
) -> Result<usize>
fn finish(
&mut self,
_output: &mut OutBuffer<'_>,
finished_frame: bool
) -> Result<usize>
Finishes the operation, writing any footer if necessary. Read more
Auto Trait Implementations
impl RefUnwindSafe for Decoder
impl Send for Decoder
impl !Sync for Decoder
impl Unpin for Decoder
impl UnwindSafe for Decoder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more