forked from organicmaps/organicmaps
Minor code style fixes.
This commit is contained in:
parent
233683d167
commit
09bb6f9411
2 changed files with 9 additions and 2 deletions
|
@ -13,11 +13,13 @@ sl::SloynikEngine::SloynikEngine(string const & dictionaryPath,
|
|||
FileReader * pDicFileReader = new FileReader(dictionaryPath);
|
||||
// m_pDictionary takes ownership of pDicFileReader.
|
||||
m_pDictionary.reset(new sl::SlofDictionary(pDicFileReader));
|
||||
|
||||
vector<uint64_t> stamp;
|
||||
stamp.push_back(strFn.m_PrimaryCompareId);
|
||||
stamp.push_back(strFn.m_SecondaryCompareId);
|
||||
stamp.push_back(m_pDictionary->KeyCount());
|
||||
stamp.push_back(pDicFileReader->Size());
|
||||
|
||||
string const stampPath = indexPath + ".stamp";
|
||||
bool needIndexBuild = false;
|
||||
try
|
||||
|
@ -33,11 +35,13 @@ sl::SloynikEngine::SloynikEngine(string const & dictionaryPath,
|
|||
needIndexBuild = true;
|
||||
}
|
||||
}
|
||||
catch (RootException &)
|
||||
catch (RootException const &)
|
||||
{
|
||||
needIndexBuild = true;
|
||||
}
|
||||
|
||||
LOG(LINFO, ("Started sloynik engine. Words in the dictionary:", m_pDictionary->KeyCount()));
|
||||
|
||||
// Uncomment to always rebuild the index: needIndexBuild = true;
|
||||
if (needIndexBuild)
|
||||
{
|
||||
|
|
|
@ -1,12 +1,15 @@
|
|||
#include "sloynik_index.hpp"
|
||||
#include "dictionary.hpp"
|
||||
|
||||
#include "../coding/file_writer.hpp"
|
||||
#include "../coding/timsort/timsort.hpp"
|
||||
|
||||
#include "../base/assert.hpp"
|
||||
#include "../base/logging.hpp"
|
||||
#include "../base/cache.hpp"
|
||||
|
||||
#include "../std/bind.hpp"
|
||||
|
||||
#include "../coding/timsort/timsort.hpp"
|
||||
|
||||
#define FILE_SORTER_LOG_BATCH_SIZE 11
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue