29 lines
523 B
C
29 lines
523 B
C
|
#pragma once
|
||
|
#include <string>
|
||
|
#include <time.h>
|
||
|
#include "../Logger.h"
|
||
|
#include "../external/SQLiteCpp/SQLiteCpp.h"
|
||
|
using namespace std;
|
||
|
|
||
|
class LogBean
|
||
|
{
|
||
|
public:
|
||
|
LogBean();
|
||
|
~LogBean();
|
||
|
static void CreateIfNoExist(SQLite::Database* db);
|
||
|
|
||
|
public:
|
||
|
long m_Id;
|
||
|
time_t m_InsertTime;
|
||
|
int m_Level;
|
||
|
string m_Content;
|
||
|
|
||
|
public:
|
||
|
static const string LOG_TABLE_NAME;
|
||
|
static const string LOG_FIELD_ID;
|
||
|
static const string LOG_FIELD_INSERT_TIME;
|
||
|
static const string LOG_FIELD_LEVEL;
|
||
|
static const string LOG_FIELD_CONTENT;
|
||
|
};
|
||
|
|