MCPcopy Create free account
hub / github.com/Tencent/TAD_Sim / parse

Method parse

common/map_sdk/map_import/src/OpenDriveStruct.cpp:75–98  ·  view source on GitHub ↗

ODHeader*/

Source from the content-addressed store, hash-verified

73
74/*ODHeader*/
75bool ODHeader::parse(XMLElement* element) {
76 ELE_CKECK;
77
78 north = element->DoubleAttribute("north");
79 south = element->DoubleAttribute("south");
80 east = element->DoubleAttribute("east");
81 west = element->DoubleAttribute("west");
82 if (element->Attribute("vendor")) {
83 vendor = element->Attribute("vendor");
84 }
85 if (element->Attribute("revMajor")) {
86 remajor = element->Int64Attribute("revMajor");
87 }
88 if (element->Attribute("revMinor")) {
89 reminor = element->Int64Attribute("revMinor");
90 }
91 if (element->Attribute("date")) {
92 date = element->Attribute("date");
93 }
94 XMLElement* geo_ref = element->FirstChildElement("geoReference");
95 if (geo_ref) coord_str = geo_ref->GetText();
96
97 return true;
98}
99
100void ODHeader::getBBox(double& n, double& s, double& e, double& w) {
101 n = north;

Callers

nothing calls this directly

Calls 15

StrCheckEmptyFunction · 0.85
absFunction · 0.85
maxFunction · 0.85
isinfFunction · 0.85
swapFunction · 0.85
pointToRectDistanceFunction · 0.85
setLengthMethod · 0.80
parseTunnelMethod · 0.80
AttributeMethod · 0.45
push_backMethod · 0.45
emptyMethod · 0.45
insertMethod · 0.45

Tested by

no test coverage detected