MCPcopy Create free account
hub / github.com/BehaviorTree/Groot / VerifyXML

Function VerifyXML

bt_editor/XML_utilities.cpp:181–201  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

179}
180
181bool VerifyXML(QDomDocument &doc,
182 const std::vector<QString>& registered_ID,
183 std::vector<QString>& error_messages)
184{
185 error_messages.clear();
186 try {
187 std::string xml_text = doc.toString().toStdString();
188 std::set<std::string> registered_nodes;
189
190 for(const auto& str: registered_ID)
191 {
192 registered_nodes.insert( str.toStdString() );
193 }
194
195 BT::VerifyXML(xml_text, registered_nodes); // may throw
196 } catch (std::exception& ex)
197 {
198 error_messages.push_back(ex.what());
199 }
200 return true;
201}
202
203
204

Callers 1

loadFromXMLMethod · 0.85

Calls 1

clearMethod · 0.45

Tested by

no test coverage detected