一.写入
qCritical() << "Error: cannot create folder.";
xml_node root = doc.append_child("map");
root.append_attribute("generator")="map editor";
root.append_attribute("upload")="true";
root.append_attribute("version")="0.6";
for (const auto& pair : points)
xml_node node = roadToPointsNode(pair.second, root);
for (const auto& pair : lines)
xml_node node = roadToLinesNode(pair.second, root);
for (const auto& pair : curves)
xml_node node = roadToLinesNode(pair.second, root);
doc.save_file((path+"/road_map.xml").toStdString().c_str());