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

Function ToString

libs/routing/router.cpp:7–20  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5namespace routing
6{
7std::string ToString(RouterType type)
8{
9 switch (type)
10 {
11 case RouterType::Vehicle: return "vehicle";
12 case RouterType::Pedestrian: return "pedestrian";
13 case RouterType::Bicycle: return "bicycle";
14 case RouterType::Transit: return "transit";
15 case RouterType::Ruler: return "ruler";
16 case RouterType::Count: return "count";
17 }
18 ASSERT(false, ());
19 return "Error";
20}
21
22RouterType FromString(std::string const & str)
23{

Callers 4

DebugPrintFunction · 0.70
IndexRouterMethod · 0.70
UNIT_TESTFunction · 0.50
PushErrorMethod · 0.50

Calls 1

ASSERTFunction · 0.85

Tested by 1

UNIT_TESTFunction · 0.40