Skip to main content

nodedb_query/msgpack_scan/
mod.rs

1// SPDX-License-Identifier: Apache-2.0
2
3//! Zero-deserialization binary scanner for MessagePack documents.
4//!
5//! Operates directly on `&[u8]` MessagePack bytes without decoding into
6//! `serde_json::Value` or `nodedb_types::Value`. Field extraction, numeric
7//! reads, comparisons, and hashing all work on raw byte offsets.
8
9pub mod aggregate_helpers;
10pub mod compare;
11pub mod compare_decimal;
12pub mod field;
13pub mod filter;
14pub mod group_key;
15pub mod index;
16pub mod kv_body;
17pub mod kv_row;
18pub mod reader;
19pub mod sidecar;
20pub mod writer;
21
22pub use compare::{compare_field_bytes, hash_field_bytes};
23pub use compare_decimal::{compare_decimal_field_bytes, decimal_reading};
24pub use field::{extract_field, extract_path};
25pub use group_key::build_group_key;
26pub use index::FieldIndex;
27pub use kv_body::{
28    KvBodyError, KvBodyShape, kv_body_shape, kv_body_to_row, kv_row_to_body_fields, row_to_kv_body,
29};
30pub use kv_row::kv_row_msgpack;
31pub use reader::{
32    array_header, map_header, read_bin_advance, read_bool, read_f64, read_i64, read_integer,
33    read_null, read_str, read_str_advance, read_u32_advance, read_value, skip_value,
34};
35pub use sidecar::{
36    SidecarEntry, SidecarFieldIndex, build_sidecar, field_index_from_sidecar, has_sidecar,
37    msgpack_bytes, sidecar_lookup,
38};
39pub use writer::{
40    build_str_map, inject_str_field, merge_fields, write_array_header, write_bin, write_bool,
41    write_f64, write_i64, write_instant, write_kv_bool, write_kv_f64, write_kv_i64,
42    write_kv_instant, write_kv_null, write_kv_raw, write_kv_str, write_map_header, write_null,
43    write_str,
44};