Skip to main content

cover_axis_range

Function cover_axis_range 

Source
pub fn cover_axis_range(
    begin_key: u128,
    end_key: u128,
    config: &DyadicCovererConfig,
) -> Vec<DyadicNode>
Expand description

Cover the inclusive key range [begin_key, end_key] with dyadic nodes.

First computes the exact canonical decomposition (greedy largest-node walk with single-key boundary leaves; tiles the range precisely, at most two nodes per level). When it exceeds max_nodes, falls back to the FINEST single grid level within [min_level, max_level] whose aligned node count fits the budget, snapping the range outward (begin down; the inclusive end is covered by its own aligned node) — a valid superset whose stick-out is bounded by one grid width per side. The exact begin/end pair rides every posting value, so stick-out costs candidate volume only, never correctness. Output nodes are sorted by start key.