Skip to main content

JfifWrite

Trait JfifWrite 

Source
pub trait JfifWrite {
    // Required method
    fn write_all(&mut self, buf: &[u8]) -> Result<(), EncodingError>;
}
Expand description

A no_std alternative for std::io::Write

An implementation of a subset of std::io::Write necessary to use the encoder without std. This trait is implemented for std::io::Write if the std feature is enabled.

Required Methods§

Source

fn write_all(&mut self, buf: &[u8]) -> Result<(), EncodingError>

Writes the whole buffer. The behavior must be identical to std::io::Write::write_all

§Errors

Return an error if the data can’t be written

Dyn Compatibility§

This trait is dyn compatible.

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

Implementors§

Source§

impl<W: Write + ?Sized> JfifWrite for W

Available on crate feature std only.