pub trait IntRepr {
type Primitive: Debug + Default + Copy + Eq + Ord + Hash;
const SIZE: Option<usize>;
// Required methods
fn serialize(val: Self::Primitive, buf: &mut Vec<u8>);
fn deserialize(buf: &mut ParseBuf<'_>) -> Result<Self::Primitive>;
}
Expand description
Serialized representation of an integer.
Required Associated Constants§
Required Associated Types§
Required Methods§
fn serialize(val: Self::Primitive, buf: &mut Vec<u8>)
fn deserialize(buf: &mut ParseBuf<'_>) -> Result<Self::Primitive>
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.