XX CMake Package
Loading...
Searching...
No Matches
XXLogFile.h
Go to the documentation of this file.
1#ifndef XXLogFileH
2#define XXLogFileH
3
4#include "XXLogExportDef.h"
5
7#include <QFile>
8
9#include <QDateTime>
10
11namespace XX
12{
15
17 {
18 static QString appendTimeStampToFileName(const QString& fileName, const QDateTime& timestamp = QDateTime::currentDateTime());
19 };
20
24
25 template <CompileTimeString tag>
26 class LogFile : public QFile
27 {
28 public:
29 LogFile(const QString& fileName);
31
32 public:
33 static QTextStream stream();
35 void changeFileName(const QString& fileName);
36
37 private:
38 static LogFile* me;
39 };
40} // namespace XX
41
42#ifndef XXLogFileHPP
43#include "XXLogFile.hpp"
44#endif // NOT XXLogFileHPP
45
46#endif // NOT LogFileH
#define XXLOG_DECLSPEC
Definition XXLogExportDef.h:11
LogFile(const QString &fileName)
void changeFileName(const QString &fileName)
closes file and opens it with a new filename
static QTextStream stream()
Definition XXPopulatedAbstract.h:11
log file base
Definition XXLogFile.h:17
static QString appendTimeStampToFileName(const QString &fileName, const QDateTime &timestamp=QDateTime::currentDateTime())