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

Function LinePropertiesFromXML

tools/openlr/openlr_model_xml.cpp:131–158  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

129}
130
131bool LinePropertiesFromXML(pugi::xml_node const & linePropNode, openlr::LocationReferencePoint & locPoint)
132{
133 if (!linePropNode)
134 {
135 LOG(LERROR, ("linePropNode is NULL"));
136 return false;
137 }
138
139 if (!TableValueFromXML(linePropNode.child("olr:frc"), locPoint.m_functionalRoadClass))
140 {
141 LOG(LERROR, ("Can't parse functional road class"));
142 return false;
143 }
144
145 if (!TableValueFromXML(linePropNode.child("olr:fow"), locPoint.m_formOfWay))
146 {
147 LOG(LERROR, ("Can't parse form of a way"));
148 return false;
149 }
150
151 if (!ValueFromXML(linePropNode.child("olr:bearing"), locPoint.m_bearing))
152 {
153 LOG(LERROR, ("Can't parse bearing"));
154 return false;
155 }
156
157 return true;
158}
159
160bool PathPropertiesFromXML(pugi::xml_node const & locPointNode, openlr::LocationReferencePoint & locPoint)
161{

Callers 1

Calls 2

TableValueFromXMLFunction · 0.85
ValueFromXMLFunction · 0.85

Tested by

no test coverage detected