Implement class for handling filesystem paths

PR #15915.
This commit is contained in:
Vladimir Golovnev
2022-02-08 06:03:48 +03:00
committed by GitHub
parent facfa26eed
commit dd1bd8ad10
131 changed files with 2252 additions and 1868 deletions

View File

@@ -32,6 +32,8 @@
#include <QObject>
#include <QTimer>
#include "base/path.h"
namespace Log
{
struct Msg;
@@ -50,10 +52,10 @@ public:
YEARS
};
FileLogger(const QString &path, bool backup, int maxSize, bool deleteOld, int age, FileLogAgeType ageType);
FileLogger(const Path &path, bool backup, int maxSize, bool deleteOld, int age, FileLogAgeType ageType);
~FileLogger();
void changePath(const QString &newPath);
void changePath(const Path &newPath);
void deleteOld(int age, FileLogAgeType ageType);
void setBackup(bool value);
void setMaxSize(int value);
@@ -66,7 +68,7 @@ private:
void openLogFile();
void closeLogFile();
QString m_path;
Path m_path;
bool m_backup;
int m_maxSize;
QFile m_logFile;