Skip to main content

subdivide

Function subdivide 

Source
pub fn subdivide<T, E>(
    roots: impl IntoIterator<Item = T>,
    order: Order,
    max_nodes: usize,
    visit: impl FnMut(T, usize) -> Result<Split<T>, E>,
) -> Result<Searched, E>
Expand description

Searches roots — in their order — and every piece a visit restricts or splits them into, visiting at most max_nodes pieces. visit gets a piece and the budget left after it (for a search of its own) and says what to do with it.