pub trait MessageSerde: Default + Clone + Sized {
    // Required methods
    fn serialize_message_part(
        &self,
        output: &mut Vec<u8>
    ) -> Result<(), MessageSerdeError>;
    fn deserialize_message_part(
        input: &mut dyn Read
    ) -> Result<Self, MessageSerdeError>;
}
Expand description

Implemented for all types that can be serialized in a message.

Required Methods§

source

fn serialize_message_part( &self, output: &mut Vec<u8> ) -> Result<(), MessageSerdeError>

Serialize this to a Vec<u8>.

source

fn deserialize_message_part( input: &mut dyn Read ) -> Result<Self, MessageSerdeError>

Deserialize this if possible.

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl MessageSerde for bool

source§

impl MessageSerde for f32

source§

impl MessageSerde for f64

source§

impl MessageSerde for i8

source§

impl MessageSerde for i16

source§

impl MessageSerde for i32

source§

impl MessageSerde for i64

source§

impl MessageSerde for u8

source§

impl MessageSerde for u16

source§

impl MessageSerde for u32

source§

impl MessageSerde for u64

source§

impl MessageSerde for ()

source§

impl MessageSerde for ProceduralMaterialHandle

source§

impl MessageSerde for ProceduralMeshHandle

source§

impl MessageSerde for ProceduralSamplerHandle

source§

impl MessageSerde for ProceduralTextureHandle

source§

impl MessageSerde for ProceduralMaterialHandle

source§

impl MessageSerde for ProceduralMeshHandle

source§

impl MessageSerde for ProceduralSamplerHandle

source§

impl MessageSerde for ProceduralTextureHandle

source§

impl MessageSerde for Mat4

source§

impl MessageSerde for Quat

source§

impl MessageSerde for Vec4

source§

impl MessageSerde for Vec2

source§

impl MessageSerde for Vec3

source§

impl MessageSerde for IVec2

source§

impl MessageSerde for IVec3

source§

impl MessageSerde for IVec4

source§

impl MessageSerde for UVec2

source§

impl MessageSerde for UVec3

source§

impl MessageSerde for UVec4

source§

impl MessageSerde for String

source§

impl MessageSerde for Duration

source§

impl<T> MessageSerde for Option<T>
where T: MessageSerde,

source§

impl<T> MessageSerde for Vec<T>
where T: MessageSerde,

Implementors§