pub trait Encoder {
type Output;
type Error;
// Required method
fn encode(&self, input: &[u8]) -> Result<Self::Output, Self::Error>;
}Expand description
Encodes raw input bytes into a concrete output type.
Implementations can produce a full QR code, an intermediate bit stream, or a
third-party symbol type. The input is borrowed to keep the trait usable in
no_std + alloc environments without requiring an owned buffer.
Required Associated Types§
Required Methods§
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".