Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/filesystem/filesystem.h')
-rw-r--r--src/filesystem/filesystem.h26
1 files changed, 18 insertions, 8 deletions
diff --git a/src/filesystem/filesystem.h b/src/filesystem/filesystem.h
index 1685fd2..83e93c0 100644
--- a/src/filesystem/filesystem.h
+++ b/src/filesystem/filesystem.h
@@ -7,7 +7,9 @@
#ifndef __INCLUDED_FILESYSTEM_H__
#define __INCLUDED_FILESYSTEM_H__
-// C++ headers
+#include "filesystem/file.h"
+#include "filesystem/diskfile.h"
+
#include <string>
/// The filesystem namespace contains classes and functions for common file operations.
@@ -17,25 +19,33 @@ namespace filesystem {
/// location of the main data files, includes trailing /
extern std::string datadir;
+
/// location of the personal data files, includes trailing /
extern std::string homedir;
+
+/// writeable location
+extern std::string writedir;
+
/// subdirectory with the base data files, includes trailing /
extern std::string basedir;
+
/// subdirectory for the current mod, includes trailing /
extern std::string moddir;
-/// Initialize the filesystem subsystem
+/// initialize the filesystem subsystem
void init();
-/// Shutdown the filesystem subsystem
+/// shutdown the filesystem subsystem
void shutdown();
-} // namespace filesystem
+/// open a file and return a pointer to a File instance
+File *open(const char *filename);
+/// open a file and return a pointer to a File instance
+File *open(const std::string &filename);
+/// close and delete a file instance
+void close(File *file);
-// project headers
-#include "filesystem/file.h"
-#include "filesystem/path.h"
-#include "filesystem/inifile.h"
+} // namespace filesystem
#endif // __INCLUDED_FILYSYSTEM_H__