| 277 | } |
| 278 | |
| 279 | bool hasExtension(const std::string& path, const std::string& ext) |
| 280 | { |
| 281 | if (path.size() < ext.size()) |
| 282 | return false; |
| 283 | |
| 284 | // Case insensitive extension comparison |
| 285 | auto pathEnd = path.substr(path.size() - ext.size()); |
| 286 | std::transform(pathEnd.begin(), pathEnd.end(), pathEnd.begin(), ::tolower); |
| 287 | return pathEnd == ext; |
| 288 | } |
| 289 | } // namespace |
| 290 | |
| 291 | bool exportData(const std::string& filePath) |
no test coverage detected