123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172 |
- #ifndef ASTANDARDPATHS_H
- #define ASTANDARDPATHS_H
- #include <QStandardPaths>
- #include <QString>
- #include <QHash>
- #include <QDir>
- class AStandardPaths{
- public:
- enum Directories {
- Database,
- Templates,
- Backup,
- Log,
- JSON
- };
- private:
- static QHash<Directories, QDir> directories;
-
- static bool scan_directories();
- public:
-
- static bool setup();
-
- static const QDir &directory(Directories location);
-
- static const QString asChildOfDir(Directories location, const QString& filename);
-
- static const QHash<Directories, QDir> &allDirectories();
- };
- #endif
|