diff options
author | Yury Melnichek <melnichek@malinovka.local> | 2011-08-16 13:24:53 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 01:21:49 +0300 |
commit | c511d2caf25560e5441b50f3be68fdaebcb67199 (patch) | |
tree | 3b36296f2f3c24298bf928a657c644648e121ef4 /search/engine.cpp | |
parent | 3662b2efe60582f7fde1185377c02c12dbbe5963 (diff) |
[search] Integrate search of a trie into main code. Not finished!
Diffstat (limited to 'search/engine.cpp')
-rw-r--r-- | search/engine.cpp | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/search/engine.cpp b/search/engine.cpp index c658009ec4..71f96cf4ff 100644 --- a/search/engine.cpp +++ b/search/engine.cpp @@ -14,9 +14,9 @@ namespace search { Engine::Engine(IndexType const * pIndex, - CategoriesHolder & categories, - TrieIterator const * pTrieIterator) - : m_pIndex(pIndex), m_pTrieIterator(pTrieIterator), m_pCategories(new CategoriesHolder()), + CategoriesHolder & categories) + : m_pIndex(pIndex), m_pTrieIterator(pIndex->GetWorldSearchIndex()), + m_pCategories(new CategoriesHolder()), m_pRunner(new threads::ConcurrentRunner), m_pLastQuery(NULL), m_queriesActive(0) { @@ -35,7 +35,8 @@ void Engine::Search(string const & queryText, { LOG(LDEBUG, (queryText, rect)); - impl::Query * pQuery = new impl::Query(queryText, rect, m_pIndex, this, m_pCategories.get()); + impl::Query * pQuery = + new impl::Query(queryText, rect, m_pIndex, this, m_pCategories.get(), m_pTrieIterator); { threads::MutexGuard mutexGuard(m_mutex); |