MCPcopy Create free account
hub / github.com/comaps/comaps / ReadStringsFromFile

Function ReadStringsFromFile

libs/search/search_quality/helpers.cpp:82–94  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

80}
81
82void ReadStringsFromFile(string const & path, vector<string> & result)
83{
84 ifstream stream(path.c_str());
85 CHECK(stream.is_open(), ("Can't open", path));
86
87 string s;
88 while (getline(stream, s))
89 {
90 strings::Trim(s);
91 if (!s.empty())
92 result.emplace_back(s);
93 }
94}
95
96void SetPlatformDirs(string const & dataPath, string const & mwmPath)
97{

Callers 2

InitDataSourceFunction · 0.85
RunRequestsFunction · 0.85

Calls 3

TrimFunction · 0.85
emptyMethod · 0.45
emplace_backMethod · 0.45

Tested by

no test coverage detected