S_New4/src/logger.h

34 行
558 B
C

#ifndef LOGGER_H
#define LOGGER_H
2022-03-25 21:50:29 +01:00
#include <iostream>
#include <fstream>
#include <string>
#include <streambuf>
#include <ctime> // std::time, localtime ...
class Logger
{
public:
Logger(std::string logFilePath);
~Logger();
std::string getFilePath();
std::fstream file;
int logCommandLine(std::string logText);
int logSubLine(std::string line);
std::string getLogText();
int clearFile();
private:
std::string filePath;
int writetoFile(std::string t);
int openFile(std::string path);
};
#endif // LOGGER_H