Crate tbon

source ·
Expand description

Library for encoding Rust program data into a binary stream, and decoding that stream.

Example:

let expected = ("one".to_string(), 2.0, vec![3, 4], vec![5u8]);
let stream = tbon::en::encode(&expected).unwrap();
let actual = block_on(tbon::de::try_decode((), stream)).unwrap();
assert_eq!(expected, actual);

Modules

  • Decode a Rust data structure from a TBON-encoded stream.
  • Encode a Rust data structure into a TBON stream.