Go to the documentation of this file.00001
00002
00003 #ifndef _FILE_SYSTEM_H_
00004 #define _FILE_SYSTEM_H_
00005
00006 #include <EngineConfig.h>
00007 #include <core/Types.h>
00008
00009 #include <string>
00010 #include <list>
00011 #include <map>
00012
00013 namespace resource
00014 {
00015 class DataStream;
00016 }
00017
00018 namespace platform
00019 {
00020
00021 class ENGINE_PUBLIC_EXPORT FileSystem
00022 {
00023 public:
00024
00025 FileSystem(const std::string& path);
00026 virtual ~FileSystem();
00027
00029 const u32& getFileSystemID() const;
00030
00031 const std::string& getPath() const;
00032
00034 virtual bool isCaseSensitive() const = 0;
00035
00037 virtual bool exists(const std::string& filename) = 0;
00038
00039 virtual resource::DataStream* open(const std::string& filename) = 0;
00040
00041 virtual void list(std::list<std::string>& ls, bool recursive = true, bool dirs = false) = 0;
00042
00043 protected:
00044
00045 u32 mFileSystemID;
00046
00047
00048 static u32 msNextGeneratedFileSytemID;
00049
00051 std::string mPath;
00052 };
00053
00054 }
00055
00056 #endif