Trait libtqsm::Language

source ·
pub trait Language {
Show 15 methods // Required method fn language_code(&self) -> &'static str; // Provided methods fn quote_pairs_regex(&self) -> &'static Regex { ... } fn numbered_reference_regex(&self) -> &Regex { ... } fn sentence_break_regex(&self) -> &Regex { ... } fn get_lastword<'a>(&'a self, text: &'a str) -> Option<&'a str> { ... } fn find_boundary<'a>( &self, text: &'a str, grapheme_indices: &HashMap<usize, &str>, cursor: &GraphemeCursor, mtch: Match<'a> ) -> Option<(usize, bool)> { ... } fn continue_in_next_word(&self, text_after_boundary: &str) -> bool { ... } fn get_skippable_ranges(&self, text: &str) -> Vec<(usize, usize)> { ... } fn segment(&self, text: &str) -> Vec<String> { ... } fn is_punctuation_between_quotes(&self) -> bool { ... } fn is_abbreviation(&self, head: &str, _tail: &str, separator: &str) -> bool { ... } fn is_exclamation_word(&self, head: &str, _tail: &str) -> bool { ... } fn abbreviation_char(&self) -> &'static str { ... } fn abbreviations(&self) -> &'static HashSet<&'static str> { ... } fn exclamation_words(&self) -> &'static HashSet<&'static str> { ... }
}

Required Methods§

source

fn language_code(&self) -> &'static str

Provided Methods§

source

fn quote_pairs_regex(&self) -> &'static Regex

source

fn numbered_reference_regex(&self) -> &Regex

source

fn sentence_break_regex(&self) -> &Regex

source

fn get_lastword<'a>(&'a self, text: &'a str) -> Option<&'a str>

source

fn find_boundary<'a>( &self, text: &'a str, grapheme_indices: &HashMap<usize, &str>, cursor: &GraphemeCursor, mtch: Match<'a> ) -> Option<(usize, bool)>

source

fn continue_in_next_word(&self, text_after_boundary: &str) -> bool

source

fn get_skippable_ranges(&self, text: &str) -> Vec<(usize, usize)>

source

fn segment(&self, text: &str) -> Vec<String>

source

fn is_punctuation_between_quotes(&self) -> bool

source

fn is_abbreviation(&self, head: &str, _tail: &str, separator: &str) -> bool

source

fn is_exclamation_word(&self, head: &str, _tail: &str) -> bool

source

fn abbreviation_char(&self) -> &'static str

source

fn abbreviations(&self) -> &'static HashSet<&'static str>

source

fn exclamation_words(&self) -> &'static HashSet<&'static str>

Implementors§