Welcome to mirror list, hosted at ThFree Co, Russian Federation.

feature_processor.hpp « indexer - github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 10770e77d03a0d99687835c21c270e7cc6315fae (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#pragma once

#include "indexer/features_vector.hpp"

#include "coding/file_reader.hpp"
#include "coding/file_container.hpp"

#include <memory>
#include <string>
#include <utility>

namespace feature
{
template <class ToDo>
void ForEachFromDat(ModelReaderPtr reader, ToDo && toDo)
{
  FeaturesVectorTest features((FilesContainerR(reader)));
  features.GetVector().ForEach(std::forward<ToDo>(toDo));
}

template <class ToDo>
void ForEachFromDat(std::string const & fPath, ToDo && toDo)
{
  ForEachFromDat(std::make_unique<FileReader>(fPath), std::forward<ToDo>(toDo));
}
}  // namespace feature