VHISTlib  1.84.0.3018
/daten/ahuesgen/projects/vhist/code/vhistlib/include/shared/logsource.h
00001 /* $HEADERS
00002  $Id: logsource.h 2179 2011-06-24 09:03:24Z ahuesgen $
00003  */
00004 
00005 #ifndef VL_LOGSOURCE_INCLUDED
00006 #define VL_LOGSOURCE_INCLUDED
00007 
00008 #include <QObject>
00009 #include "misc_defines.h"
00010 
00011 #include <QMetaType>
00012 
00013 namespace vhist
00014 {
00015 
00024 class VHIST_EXTERN LogSource : public QObject
00025 {
00026     public:
00031         enum LogType
00032         {
00033             LOG_MESSAGE ,
00034             LOG_WARNING ,
00035             LOG_ERROR 
00036         };
00037             
00038     Q_OBJECT
00039     public:
00040         LogSource(QObject* listener = NULL);
00041         virtual ~LogSource();
00042 
00043     public:
00044         void publishToLogSlot(QObject* listener);
00045         void publishToLogSignal(QObject* listener);
00046 
00047     signals:
00048         //void log(const QString msg, const vhist::LogSource::LogType type = LOG_MESSAGE);
00049         void log(const QString msg, const int type = LOG_MESSAGE);
00050 };
00051 
00052 }
00053 
00054 Q_DECLARE_METATYPE(vhist::LogSource::LogType)
00055 
00056 #endif // VL_LOGSOURCE_INCLUDED
00057 

VHISTlib 1.84.0.3018 of Jun 28 2013, generated by doxygen.