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

Method ValidateAndFormat_destination

generator/osm2meta.cpp:187–201  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

185}
186
187std::string MetadataTagProcessorImpl::ValidateAndFormat_destination(std::string const & v)
188{
189 // Normalization. "a1 a2;b1-b2; c,d ;e,;f; ;g" -> "a1 a2; b1-b2; c; d; e; f; g"
190 std::string r;
191 strings::Tokenize(v, ";,", [&](std::string_view d)
192 {
193 strings::Trim(d);
194 if (d.empty())
195 return;
196 if (!r.empty())
197 r += "; ";
198 r.append(d);
199 });
200 return r;
201}
202
203std::string MetadataTagProcessorImpl::ValidateAndFormat_destination_ref(std::string const & v)
204{

Callers

nothing calls this directly

Calls 4

TrimFunction · 0.85
TokenizeFunction · 0.50
emptyMethod · 0.45
appendMethod · 0.45

Tested by

no test coverage detected