pub struct TableFinder { /* private fields */ }Expand description
Orchestrator for the table detection pipeline.
Takes edges (and optionally words/chars) and settings, then runs the appropriate detection strategy to produce tables.
Implementations§
Source§impl TableFinder
impl TableFinder
Sourcepub fn new(edges: Vec<Edge>, settings: TableSettings) -> Self
pub fn new(edges: Vec<Edge>, settings: TableSettings) -> Self
Create a new TableFinder with the given edges and settings.
Sourcepub fn new_with_words(
edges: Vec<Edge>,
words: Vec<Word>,
settings: TableSettings,
) -> Self
pub fn new_with_words( edges: Vec<Edge>, words: Vec<Word>, settings: TableSettings, ) -> Self
Create a new TableFinder with edges, words, and settings.
The words are used by the Stream strategy to generate synthetic edges from text alignment patterns.
Sourcepub fn settings(&self) -> &TableSettings
pub fn settings(&self) -> &TableSettings
Get a reference to the settings.
Sourcepub fn find_tables(&self) -> Vec<Table>
pub fn find_tables(&self) -> Vec<Table>
Run the table detection pipeline and return detected tables.
Pipeline: filter edges → snap → join → intersections → cells → tables.
For Lattice strategy, all edges (lines + rect edges) are used. For LatticeStrict strategy, only line-sourced edges are used (no rect edges). For Stream strategy, synthetic edges are generated from word alignment patterns. For Explicit strategy, edges from user-provided coordinates are used, combined with any detected edges passed to the finder (mixing).