shared: Indexer: IndexResult: Introduce failedResults()

这个提交包含在:
Albert S. 2022-06-23 15:25:21 +02:00
父节点 0867ab294d
当前提交 e99b2ba091

查看文件

@ -22,19 +22,30 @@ class IndexResult
return addedPaths + skippedPaths + erroredPaths;
}
QVector<QString> failedPaths() const
QVector<FileScanResult> failedResults() const
{
QVector<QString> result;
QVector<FileScanResult> result;
std::for_each(results.begin(), results.end(),
[&result](FileScanResult res)
{
if(res.second == DBFAIL || res.second == PROCESSFAIL || res.second == NOTFOUND)
if(res.second == DBFAIL || res.second == PROCESSFAIL || res.second == NOTFOUND ||
res.second == NOACCESS)
{
result.append(res.first);
result.append(res);
}
});
return result;
}
QVector<QString> failedPaths() const
{
QVector<QString> result;
QVector<FileScanResult> results = failedResults();
std::for_each(results.begin(), results.end(), [&result](FileScanResult res) { result.append(res.first); });
return result;
}
};
class Indexer : public QObject