2014-08-21 07:58:11 +00:00
|
|
|
#ifndef FILESYSTEM_H
|
|
|
|
#define FILESYSTEM_H
|
|
|
|
|
|
|
|
#include "system_global.h"
|
|
|
|
|
|
|
|
namespace paysages {
|
|
|
|
namespace system {
|
|
|
|
|
2015-11-09 21:30:46 +00:00
|
|
|
class SYSTEMSHARED_EXPORT FileSystem {
|
|
|
|
public:
|
2014-08-21 07:58:11 +00:00
|
|
|
/**
|
|
|
|
* Get an absolute path to a temporary file.
|
|
|
|
*
|
|
|
|
* filename must not contain directory separators.
|
|
|
|
*/
|
2015-12-10 23:36:50 +00:00
|
|
|
static string getTempFile(const string &filename);
|
2014-08-21 10:36:28 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns true if the given path points to a file.
|
|
|
|
*/
|
2015-12-10 23:36:50 +00:00
|
|
|
static bool isFile(const string &filepath);
|
2015-11-18 21:22:09 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Remove a file by its absolute path.
|
|
|
|
*/
|
2015-12-10 23:36:50 +00:00
|
|
|
static bool removeFile(const string &filepath);
|
2014-08-21 07:58:11 +00:00
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif // FILESYSTEM_H
|