| 540 | } |
| 541 | |
| 542 | bool FileInfo::deleteDirectoryRecursive() const |
| 543 | { |
| 544 | if (!isDir()) { |
| 545 | return false; |
| 546 | } |
| 547 | |
| 548 | try { |
| 549 | fs::path path = stringToPath(FileName); |
| 550 | return fs::remove_all(path) > 0; |
| 551 | } |
| 552 | catch (const fs::filesystem_error& e) { |
| 553 | std::clog << e.what() << '\n'; |
| 554 | return false; |
| 555 | } |
| 556 | } |
| 557 | |
| 558 | std::vector<Base::FileInfo> FileInfo::getDirectoryContent() const |
| 559 | { |
no test coverage detected