pub trait EncodedBody: Sized {
type Error;
// Required methods
fn encoded_len(&self) -> usize;
fn encode_into(&self, out: &mut [u8]) -> Result<(), Self::Error>;
// Provided method
fn into_shared(self, encoded_len: usize) -> Result<Shared, Self::Error> { ... }
}Required Associated Types§
Required Methods§
fn encoded_len(&self) -> usize
fn encode_into(&self, out: &mut [u8]) -> Result<(), Self::Error>
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".