Skip to main content

Crate msg_bebop

Crate msg_bebop 

Source
Expand description

§Msg Bebop Library

High-performance message serialization using Bebop for Rust.

§Example

use msg_bebop::Msg;
use bebop::Record;

let msg = Msg {
    body: "Hello, world!",
    from_id: "sender123",
    id: "msg456",
    to_ids: vec!["recipient1", "recipient2"],
    _type: "greeting",
};

// Serialize
let mut bytes = Vec::new();
msg.serialize(&mut bytes)?;

// Deserialize
let decoded_msg = Msg::deserialize(&bytes)?;

Structs§

Msg