export declare class TrieNode { edges: Map; isWordEnd: boolean; /** * Creates a TrieNode instance */ constructor(); /** * Inserts a new word to given node * @param {string} root root node to insert * @param {string} word word to insert */ insert(root: TrieNode, word: string): void; /** * Searches the given word inside Trie * @param {TrieNode} root node to search from * @param {string} word word to search * @returns {boolean} true if word found, false otherwise */ search(root: TrieNode, word: string): boolean; /** * Removes given word from Trie * @param {TrieNode} root node to start search from * @param {string} word word to be removed * @param {boolean} deep deep remove * @returns {boolean} whether or not the word removed */ remove(root: TrieNode, word: string, deep?: boolean): boolean; } export declare class Trie { private root; /** * Creates a Trie instance */ constructor(); /** * Inserts a new word into Trie * @param {string} word word to be inserted */ insert(word: string): void; /** * Searches given word in the Trie * @param {string} word word to be searched * @returns {boolean} */ search(word: string): boolean; /** * Removes word from thee Trie * @param {string} word word to be removed * @param {boolean} deep deep remove * @returns {boolean} whether or not the word removed */ remove(word: string, deep?: boolean): boolean; }