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

Function FormatElevation

libs/indexer/feature_utils.cpp:306–317  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

304}
305
306string FormatElevation(string_view elevation)
307{
308 if (!elevation.empty())
309 {
310 double value;
311 if (strings::to_double(elevation, value))
312 return std::string{kMountainSymbol} + platform::Distance::FormatAltitude(value);
313 else
314 LOG(LWARNING, ("Invalid elevation metadata:", elevation));
315 }
316 return {};
317}
318
319constexpr char const * kWlan = "wlan";
320constexpr char const * kWired = "wired";

Callers 2

FillDetailsFunction · 0.85
FormatSubtitleMethod · 0.85

Calls 2

to_doubleFunction · 0.50
emptyMethod · 0.45

Tested by

no test coverage detected