Currently, when including libOpenDRIVE in an external project, there is no possibility to elegantly catch XML parsing errors. The reason is that "most pugixml functions have a no-throw exception guarantee" and that libOpenDRIVE itself does not expose any additional exception handling possibility.
Exposing pugi::xml_parse_result as member variable of OpenDriveMap enables handling of parsing errors by querying the xml_parse_status from within the external project.
Currently, when including libOpenDRIVE in an external project, there is no possibility to elegantly catch XML parsing errors. The reason is that "most pugixml functions have a no-throw exception guarantee" and that libOpenDRIVE itself does not expose any additional exception handling possibility.
Exposing
pugi::xml_parse_result
as member variable ofOpenDriveMap
enables handling of parsing errors by querying thexml_parse_status
from within the external project.