messagepack-serde
messagepack for no_std with serde
Examples
use ;
let buf: & = &;
let data = .unwrap;
let expected = Data ;
assert_eq!;
let mut serialized = ;
let len = to_slice.unwrap;
assert_eq!;
Installation
Add this crate for Cargo.toml. Default support no_std.
= { = "https://github.com/tunamaguro/messagepack-rs.git" }
Features
-
no_stdsupportIf you want this crate with
std::io::Readorstd::io::Write, please add featurestdand usemessagepack_serde::from_readerormessagepack_serde::to_writer. -
Flexible Numeric Serialization
- Provides multiple numeric encoding strategies:
Exact: Encodes numeric types exactly as provided without minimization. This is default.Lossless Minimization: Minimizes numeric type size during serialization without any loss of information (e.g., encoding 1_u16 as positive fixint).Aggressive Minimization: Aggressively minimizes numeric values, including converting floats with integer values into integers for the most compact representation.
- If you want deserialize any numeric value, please use
messagepack_serde::value::Number.
- Provides multiple numeric encoding strategies:
-
extformat support
License
Licensed under either of
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.