Trait SerializeExt

Source
pub trait SerializeExt: Sized {
    // Required method
    fn serialize<'a>(
        &self,
        buffer: &'a mut [u8],
    ) -> Result<&'a [u8], SerializeError>;
}
Expand description

An extension trait to expose a nicer API to the user.

Required Methods§

Source

fn serialize<'a>( &self, buffer: &'a mut [u8], ) -> Result<&'a [u8], SerializeError>

Serializes a SOME/IP payload type to a given slice of bytes using Serialize and returns the number of bytes written to the buffer.

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.

Implementors§

Source§

impl<T> SerializeExt for T
where T: Serialize,