Trait harper_core::Dictionary

source ·
pub trait Dictionary: Send + Sync + Clone {
    // Required methods
    fn contains_word(&self, word: &[char]) -> bool;
    fn words_iter(&self) -> impl Iterator<Item = &[char]>;
    fn words_with_len_iter(
        &self,
        len: usize
    ) -> Box<dyn Iterator<Item = &[char]> + '_>;
}

Required Methods§

source

fn contains_word(&self, word: &[char]) -> bool

source

fn words_iter(&self) -> impl Iterator<Item = &[char]>

source

fn words_with_len_iter( &self, len: usize ) -> Box<dyn Iterator<Item = &[char]> + '_>

Iterate over all the words in the dictionary of a given length

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl<D: Dictionary + ?Sized> Dictionary for Arc<D>

source§

fn contains_word(&self, word: &[char]) -> bool

source§

fn words_iter(&self) -> impl Iterator<Item = &[char]>

source§

fn words_with_len_iter( &self, len: usize ) -> Box<dyn Iterator<Item = &[char]> + '_>

Implementors§