[][src]Trait trie_tree::trie::basic::Trie

pub trait Trie<T: Eq + Hash + Clone> {
    fn insert_seq(node: Rc<RefCell<Node<T>>>, words: &[T], leaf: Leaf<T>) { ... }
fn get_leaf(node: Rc<RefCell<Node<T>>>, words: &[T]) -> Leaf<T> { ... }
fn find_node(
        node: Rc<RefCell<Node<T>>>,
        word: &T
    ) -> (bool, Rc<RefCell<Node<T>>>) { ... }
fn find_last_node(
        node: Rc<RefCell<Node<T>>>,
        words: &[T]
    ) -> (usize, Rc<RefCell<Node<T>>>) { ... }
fn add_leaf(node: Rc<RefCell<Node<T>>>, leaf: Leaf<T>) -> bool { ... }
fn add_node(
        node: Rc<RefCell<Node<T>>>,
        node_data: T
    ) -> Rc<RefCell<Node<T>>> { ... } }

Provided methods

fn insert_seq(node: Rc<RefCell<Node<T>>>, words: &[T], leaf: Leaf<T>)

add node chars and leaf chars to Node.

fn get_leaf(node: Rc<RefCell<Node<T>>>, words: &[T]) -> Leaf<T>

get the corresponding leaf from the char seq.

fn find_node(
    node: Rc<RefCell<Node<T>>>,
    word: &T
) -> (bool, Rc<RefCell<Node<T>>>)

get the node correspongding to char.

fn find_last_node(
    node: Rc<RefCell<Node<T>>>,
    words: &[T]
) -> (usize, Rc<RefCell<Node<T>>>)

get the last node correspongding to chars.

fn add_leaf(node: Rc<RefCell<Node<T>>>, leaf: Leaf<T>) -> bool

add leaf to the node

fn add_node(node: Rc<RefCell<Node<T>>>, node_data: T) -> Rc<RefCell<Node<T>>>

add node to the node

Loading content...

Implementors

impl<T: Eq + Hash + Clone> Trie<T> for Node<T>[src]

Loading content...