diff options
| author | Li Jin <dragon-fly@qq.com> | 2022-11-15 17:23:46 +0800 |
|---|---|---|
| committer | Li Jin <dragon-fly@qq.com> | 2022-11-15 17:52:09 +0800 |
| commit | 94f8330613877b3582d32bd11abd83a97b4399ad (patch) | |
| tree | 5359de314be1ebde17f8d1e48632a97d18f9e50f /src/3rdParty/efsw/FileSystem.hpp | |
| parent | 60f8f00a022ac08701792b2897b72d8c99b50f52 (diff) | |
| download | yuescript-94f8330613877b3582d32bd11abd83a97b4399ad.tar.gz yuescript-94f8330613877b3582d32bd11abd83a97b4399ad.tar.bz2 yuescript-94f8330613877b3582d32bd11abd83a97b4399ad.zip | |
adding -w option to Yuescript tool.
Diffstat (limited to 'src/3rdParty/efsw/FileSystem.hpp')
| -rwxr-xr-x | src/3rdParty/efsw/FileSystem.hpp | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/src/3rdParty/efsw/FileSystem.hpp b/src/3rdParty/efsw/FileSystem.hpp new file mode 100755 index 0000000..6c24386 --- /dev/null +++ b/src/3rdParty/efsw/FileSystem.hpp | |||
| @@ -0,0 +1,41 @@ | |||
| 1 | #ifndef EFSW_FILESYSTEM_HPP | ||
| 2 | #define EFSW_FILESYSTEM_HPP | ||
| 3 | |||
| 4 | #include <efsw/FileInfo.hpp> | ||
| 5 | #include <efsw/base.hpp> | ||
| 6 | #include <map> | ||
| 7 | |||
| 8 | namespace efsw { | ||
| 9 | |||
| 10 | class FileSystem { | ||
| 11 | public: | ||
| 12 | static bool isDirectory( const std::string& path ); | ||
| 13 | |||
| 14 | static FileInfoMap filesInfoFromPath( std::string path ); | ||
| 15 | |||
| 16 | static char getOSSlash(); | ||
| 17 | |||
| 18 | static bool slashAtEnd( std::string& dir ); | ||
| 19 | |||
| 20 | static void dirAddSlashAtEnd( std::string& dir ); | ||
| 21 | |||
| 22 | static void dirRemoveSlashAtEnd( std::string& dir ); | ||
| 23 | |||
| 24 | static std::string fileNameFromPath( std::string filepath ); | ||
| 25 | |||
| 26 | static std::string pathRemoveFileName( std::string filepath ); | ||
| 27 | |||
| 28 | static std::string getLinkRealPath( std::string dir, std::string& curPath ); | ||
| 29 | |||
| 30 | static std::string precomposeFileName( const std::string& name ); | ||
| 31 | |||
| 32 | static bool isRemoteFS( const std::string& directory ); | ||
| 33 | |||
| 34 | static bool changeWorkingDirectory( const std::string& path ); | ||
| 35 | |||
| 36 | static std::string getCurrentWorkingDirectory(); | ||
| 37 | }; | ||
| 38 | |||
| 39 | } // namespace efsw | ||
| 40 | |||
| 41 | #endif | ||
