pub trait EncodeBytes<C> {
// Required method
fn encode_bytes<W: Write>(
&self,
e: &mut Encoder<W>,
ctx: &mut C,
) -> Result<(), Error<W::Error>>;
// Provided method
fn is_nil(&self) -> bool { ... }
}
Expand description
Like Encode
but specific for encoding of byte slices.
Required Methods§
fn encode_bytes<W: Write>( &self, e: &mut Encoder<W>, ctx: &mut C, ) -> Result<(), Error<W::Error>>
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.