Trait hyphenation::hyphenator::Hyphenation
[−]
[src]
pub trait Hyphenation<Hyphenator> where Hyphenator: Iterator { fn opportunities(self, corp: &Corpus) -> Vec<usize>; fn hyphenate(self, corp: &Corpus) -> Hyphenator; }
Required Methods
fn opportunities(self, corp: &Corpus) -> Vec<usize>
Returns the indices of valid hyphenation points within the text.
fn hyphenate(self, corp: &Corpus) -> Hyphenator
Returns an iterator over segments of the text separated by valid hyphenation points.
When iterating over a word, such segments coincide with orthographic syllables. Note that, in some orthographies, the syllables of a hyphenated word are not necessarily substrings of the original word.