/// Returns all words found at the exact sequence of digits
Returns all words found at the exact sequence of digits
Returns all words found at the exact sequence of digits
pub fn words_at<D>(&self, digits: D) -> Vec<&str>
    where
        D: Into<Digits>,
    {
        let mut digits = digits.into();
        let mut current = self.root.as_ref();
        while let Some(index) = current {
            if let Some(digit) = digits.head() {
                current = self.nodes[*index].subtrees.get(digit);
                digits = digits.tail();
            } else {
                return self.nodes[*index].words.iter().map(AsRef::as_ref).collect();
            }
        }
        vec![]
    }
pub fn words_at < D > ( & self , digits : D ) -> Vec < & str > where D : Into < Digits > , { let mut digits = digits . into ( ) ; let mut current = self . root . as_ref ( ) ; while let Some ( index ) = current { if let Some ( digit ) = digits . head ( ) { current = self . nodes [ * index ] . subtrees . get ( digit ) ; digits = digits . tail ( ) ; } else { return self . nodes [ * index ] . words . iter ( ) . map ( AsRef :: as_ref ) . collect ( ) ; } } vec ! [ ] }
Returns all words found at the exact sequence of digits
Returns all words found at the exact sequence of digits
&self
digits
D