diff options
Diffstat (limited to 'platform/platform.hpp')
-rw-r--r-- | platform/platform.hpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/platform/platform.hpp b/platform/platform.hpp index c54f04e1e9..28698ed1c2 100644 --- a/platform/platform.hpp +++ b/platform/platform.hpp @@ -22,7 +22,10 @@ public: enum EError { ERR_OK = 0, - ERR_UNKNOWN = 1 + ERR_FILE_DOES_NOT_EXIST, + ERR_ACCESS_FAILED, + ERR_DIRECTORY_NOT_EMPTY, + ERR_UNKNOWN }; enum EFileType @@ -63,6 +66,9 @@ protected: /// Hash some unique string into uniform format. static string HashUniqueID(string const & s); + /// Returns last system call error as EError. + static EError ErrnoToError(); + public: Platform(); @@ -120,7 +126,7 @@ public: static void GetFilesByRegExp(string const & directory, string const & regexp, FilesList & outFiles); //@} - static EError GetFilesByType(string const & directory, unsigned typeMask, FilesList & outFiles); + static void GetFilesByType(string const & directory, unsigned typeMask, FilesList & outFiles); static EError GetFileType(string const & path, EFileType & type); |