-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathtechlogger.h
More file actions
39 lines (32 loc) · 799 Bytes
/
Copy pathtechlogger.h
File metadata and controls
39 lines (32 loc) · 799 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#ifndef TECHLOGGER_H
#define TECHLOGGER_H
#include <QDir>
#include <QFile>
#include <QFileDialog>
#include <QDateTime>
#include <chrono>
#include <iostream>
#include <vector>
#include <fstream>
#include <sstream>
#include <mutex>
#include <thread>
#include <condition_variable>
/**
* @brief Logging all data (all frames) and programm state on hard disk
* @details Working in separate thread
*/
class TechLogger{
public:
QString strDirPath;
QString fileName;
// DATA
std::vector<std::string> data;
bool isRunning = true;
std::mutex mutLocal;
void dropData(std::condition_variable* cond);
void updFileName(const QString& name);
void addSymb(const QString& symb);
QString getFullName(){return strDirPath + fileName + ".log";}
};
#endif // TECHLOGGER_H