source: trunk/FACT++/src/MessageDim.h@ 10379

Last change on this file since 10379 was 10373, checked in by tbretz, 14 years ago
Changed basis of MessageImp::Write function from const char* to std::string& to be able to boost::bind the function, because boost::bind will hold an internal copy of the string.
File size: 849 bytes
Line 
1#ifndef FACT_MessageDim
2#define FACT_MessageDim
3
4#include "MessageImp.h"
5
6
7
8#include <dis.hxx> // DimService
9
10class MessageDimTX : public DimService, public MessageImp
11{
12private:
13 bool fDebug;
14
15public:
16 MessageDimTX(const std::string &name, std::ostream &out=std::cout);
17 ~MessageDimTX();
18
19 int Write(const Time &t, const std::string &txt, int qos=kInfo);
20
21 void SetDebug(bool b=true) { fDebug=b; }
22};
23
24
25
26#include <dic.hxx> // DimStampedInfo
27
28class MessageDimRX : public DimInfoHandler
29{
30protected:
31 MessageImp &fMsg;
32
33private:
34 DimStampedInfo fDimMessage;
35
36 int fMinLogLevel;
37 bool fConnected;
38
39protected:
40 void infoHandler();
41
42public:
43 MessageDimRX(const std::string &name, MessageImp &imp);
44
45 void SetMinLogLevel(int min=0) { fMinLogLevel=min; }
46 bool IsConnected() const { return fConnected; }
47};
48
49#endif
Note: See TracBrowser for help on using the repository browser.