pub trait Encoder { type Error: Error; // Required method fn encode_version(&mut self, version: u32) -> Result<(), Self::Error>; }
The Encoder trait is used to encode versioned data.
Encoder
The error type for the encoder.
Encodes the version to the encoder.
This function will return an error if encoder fails to encode the version.