#binary-encoding #binary #binary-format #binary-data #serialization #stream #deserialize

tbon

TinyChain Binary Object Notation is a compact and versatile stream-friendly binary serialization format

17 releases

0.5.2 Dec 20, 2023
0.5.1 Sep 3, 2023
0.5.0 Jul 3, 2023
0.4.2 Jan 24, 2023
0.1.3 Mar 23, 2021

#1347 in Encoding

Download history 4/week @ 2024-01-01 25/week @ 2024-01-29 9/week @ 2024-02-12 22/week @ 2024-02-19 72/week @ 2024-02-26 28/week @ 2024-03-04 31/week @ 2024-03-11 42/week @ 2024-03-18 22/week @ 2024-03-25 116/week @ 2024-04-01 62/week @ 2024-04-08 12/week @ 2024-04-15

220 downloads per month
Used in 15 crates (5 directly)

Apache-2.0

65KB
2K SLoC

Tinychain Binary Object Notation

Tinychain Binary Object Notation (TBON) is a compact and versatile stream-friendly binary serialization format.

Example:

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

lib.rs:

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);

Dependencies

~1.7–3.5MB
~68K SLoC