Skip to main content

Module api

Module api 

Source
Expand description

Public API surface for jetro-experimental.

Designed for jetro-core and other downstream tools to consume without depending on internal column layouts. Internals (Stage1, StructIndex, KeyBitmaps) remain accessible for tests/benches but should not be used by library callers.

Stable types:

Stable entry points:

  • from_bytes — build a structural index from JSON bytes

Stable fused query helpers:

All iterators are lazy. Memory layout is private; future refactors can swap Roaring for any other bitmap library without breaking callers.

Structs§

Ancestors
BuildOptions
ByteSpan
KeyHits
Lazy iterator over key matches. Backed by a Roaring bitmap; supports composition (and/or) without materialising intermediate Vecs.
StructuralIndex
Opaque structural index over a JSON document. Internal layout is subject to change; consume only via the public methods.
TokenId
Opaque token handle. Internally a u32 index into the structural index.
Tokens

Enums§

Error
Public error enum. Implements std::error::Error.
TokenKind

Functions§

count_key
O(1) — popcount of the key bitmap.
find_eq
$..find(key == literal) — emit enclosing-Object token ids.
find_eq_compound
Compound $..find(k1 == l1 AND k2 == l2 ...). Conds applied within the SAME object (parent-token equality).
from_bytes
from_bytes_with
json_number_eq
Determine whether a value byte-slice is a JSON number that compares equal to the literal interpreted as a number. Used by find_eq when the caller wants numeric semantics rather than byte-for-byte match.
json_string_eq
Compare a JSON-encoded value byte-slice against a plain literal.
parse_f64
Parse a JSON number byte-slice as f64. Uses fast-float (SSE/AVX SIMD) when the feature is enabled, falls back to str::parse otherwise.
parse_i64
Parse a JSON number byte-slice as i64. Tries integer parse first, then falls back to parse_f64 (truncating fractional component).