| 1262 | } |
| 1263 | |
| 1264 | void XMLParser::PImpl::getPortsRecursively(const XMLElement* element, |
| 1265 | std::vector<std::string>& output_ports) |
| 1266 | { |
| 1267 | for(const XMLAttribute* attr = element->FirstAttribute(); attr != nullptr; |
| 1268 | attr = attr->Next()) |
| 1269 | { |
| 1270 | const char* attr_name = attr->Name(); |
| 1271 | const char* attr_value = attr->Value(); |
| 1272 | if(IsAllowedPortName(attr_name) && TreeNode::isBlackboardPointer(attr_value)) |
| 1273 | { |
| 1274 | auto port_name = TreeNode::stripBlackboardPointer(attr_value); |
| 1275 | output_ports.push_back(static_cast<std::string>(port_name)); |
| 1276 | } |
| 1277 | } |
| 1278 | |
| 1279 | for(auto child_element = element->FirstChildElement(); child_element != nullptr; |
| 1280 | child_element = child_element->NextSiblingElement()) |
| 1281 | { |
| 1282 | getPortsRecursively(child_element, output_ports); |
| 1283 | } |
| 1284 | } |
| 1285 | |
| 1286 | namespace |
| 1287 | { |
nothing calls this directly
no test coverage detected