pub trait MsgPackSerilization {
    type Output;

    // Required methods
    fn to_msgpack(&self) -> Result<Vec<u8>>;
    fn from_msgpack(data: &[u8]) -> Result<Self::Output>;
}
Expand description

A trait for serializing and deserializing to MsgPack

Required Associated Types§

source

type Output

The type of the struct implementing this trait

Required Methods§

source

fn to_msgpack(&self) -> Result<Vec<u8>>

Convert self to a msgpack encoded buffer

source

fn from_msgpack(data: &[u8]) -> Result<Self::Output>

Create the struct from a MsgPack encoded buffer

Arguments:
  • data - the MsgPack buffer

Implementors§