summaryrefslogtreecommitdiff
path: root/src/logd.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/logd.h')
-rwxr-xr-x[-rw-r--r--]src/logd.h30
1 files changed, 21 insertions, 9 deletions
diff --git a/src/logd.h b/src/logd.h
index 788015b..2d6270b 100644..100755
--- a/src/logd.h
+++ b/src/logd.h
@@ -1,25 +1,37 @@
+#include "incl.h"
+
+#ifdef LOGGING
#ifndef LOGD_H
#define LOGD_H
-#include "incl.h"
-#include "s_tool.h"
-#include "s_conf.h"
-#include <fstream>
#include <queue>
#include <time.h>
+
class logd
{
-
private:
string s_logfile;
queue<string> s_queue;
- ofstream s_output;
+ pthread_mutex_t mut_s_logging;
int i_lines;
+
+ void initialize( string s_filename, int i_log_lines );
+ void flush();
+ void set_lines( const int i_lines );
+ string get_time_string();
+
public:
- logd( string filename );
+ logd( string s_filename, string s_log_lines );
+ logd( string s_filename, int i_log_lines );
~logd();
- void flush();
- void log( map_string request );
+ void set_logfile( string s_path, string s_filename );
+ void log_access( map<string,string> &map_request );
+ void log_simple_line( string s_line );
+ void flush_logs();
+ static string remove_html_tags( string s_log );
};
+
+#endif
#endif
+