5#ifndef FLUTTER_FML_ASCII_TRIE_H_
6#define FLUTTER_FML_ASCII_TRIE_H_
23 void Fill(
const std::vector<std::string>& entries);
26 inline bool Query(
const char* argument) {
27 return !node_ ||
Query(node_.get(), argument);
A trie for looking for ASCII prefixes.
std::unique_ptr< TrieNode > TrieNodePtr
static const int kMaxAsciiValue
The max Ascii value.
bool Query(const char *argument)
Returns true if argument is prefixed by the contents of the trie.
void Fill(const std::vector< std::string > &entries)
Clear and insert all the entries into the trie.
TrieNodePtr children[kMaxAsciiValue]