Merge pull request #722 from ONLYOFFICE/release/v6.5.0

Release/v6.5.0
This commit is contained in:
Oleg Korshul
2021-09-26 16:39:51 +03:00
committed by GitHub
23 changed files with 815 additions and 352 deletions

View File

@ -53,7 +53,6 @@
#endif
#include <string.h>
#include <regex>
#include "Directory.h"
namespace NSDirectory
@ -588,19 +587,4 @@ namespace NSDirectory
{
return Exists(pathName);
}
std::vector<std::wstring> GrepPaths(const std::vector<std::wstring> &paths, const std::wstring &strRegEx)
{
std::vector<std::wstring> filtredPaths;
std::wregex regEx(strRegEx);
std::wsmatch wSmath;
for (const auto& path : paths)
{
if (std::regex_match(path, wSmath, regEx))
filtredPaths.push_back(path);
}
return filtredPaths;
}
}

View File

@ -68,7 +68,6 @@ namespace NSDirectory
KERNEL_DECL void GetFiles2(std::wstring strDirectory, std::vector<std::wstring>& oArray, bool bIsRecursion = false);
KERNEL_DECL std::vector<std::wstring> GetFiles(std::wstring strDirectory, bool bIsRecursion = false);
KERNEL_DECL std::vector<std::wstring> GrepPaths(const std::vector<std::wstring>& paths, const std::wstring& strRegEx);
KERNEL_DECL std::vector<std::wstring> GetDirectories(std::wstring strDirectory);
KERNEL_DECL bool Exists(const std::wstring& strDirectory);
KERNEL_DECL bool CreateDirectory(const std::wstring& strDirectory);