10 #ifndef CARMA_DBMS_SYSLOGLISTENERTHREAD_H
11 #define CARMA_DBMS_SYSLOGLISTENERTHREAD_H
19 #include "log4cpp/Category.hh"
23 #include "carma/util/PthreadMutex.h"
24 #include "carma/util/PthreadCond.h"
30 class SyslogListenerThread
33 SyslogListenerThread (
34 std::string pipeFileName,
35 std::queue<std::string * > *rawBufferQueue,
41 static void thread( SyslogListenerThread &This );
45 double getStartTime() {
return _timeOfStart; };
46 long long getMessageCount() {
return _messageCountFromStartOfRun; };
47 long long getTotalBytes() {
return _totalBytesReceived; };
50 std::string *waitForNextMessage();
53 log4cpp::Category &_log;
54 std::string _pipeFileName;
58 long long _messageCountFromStartOfRun;
59 long long _totalBytesReceived;
60 SyslogListenerThread *_myThread;
64 std::string::size_type _newMsgReset;
67 std::queue<std::string * > *_rawBufferQueue;
76 #endif // CARMA_DBMS_SYSLOGLISTENERTHREAD_H
A simple wrapper class that makes use of ::pthread_cond_t easier in a C++ world.
A simple wrapper class that makes use of ::pthread_mutex_t easier in a C++ world. ...