pub struct MatcherConfig {
pub threshold: f32,
pub max_threads: usize,
pub unanchored: bool,
pub best_match: bool,
pub enhance_match: bool,
pub posix: bool,
pub global: bool,
pub multi_line: bool,
pub prefer_shortest: bool,
pub unicode: bool,
pub greedy_first: bool,
}Expand description
Configuration for the matcher.
Fields§
§threshold: f32Similarity threshold (0.0 - 1.0).
max_threads: usizeMaximum number of threads (beam width).
unanchored: boolWhether to search for matches anywhere (true) or only at start (false).
best_match: boolBESTMATCH mode - find best match instead of first match.
enhance_match: boolENHANCEMATCH mode - improve the fit of the found match.
posix: boolPOSIX mode - find longest match at leftmost position.
global: boolGlobal mode - find all matches instead of stopping at first. When false (default), stops at first valid match (faster).
multi_line: boolMulti-line mode - ^ and $ match at line boundaries.
prefer_shortest: boolPrefer shortest matches (for patterns with lazy quantifiers). When true, prefers shorter matches over longer ones at the same similarity.
unicode: boolUnicode mode - enable Unicode character classes (\w, \d, \s match Unicode).
greedy_first: boolGreedy first-match mode - return first match found (faster). Similar to mrab-regex behavior.
Trait Implementations§
Source§impl Clone for MatcherConfig
impl Clone for MatcherConfig
Source§fn clone(&self) -> MatcherConfig
fn clone(&self) -> MatcherConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more