]> git.uio.no Git - u/mrichter/AliRoot.git/blob - HLT/MUON/src/DDL/L2SignalReceiver.hpp
This commit was generated by cvs2svn to compensate for changes in r11742,
[u/mrichter/AliRoot.git] / HLT / MUON / src / DDL / L2SignalReceiver.hpp
1 ////////////////////////////////////////////////////////////////////////////////
2 //
3 // Author: Artur Szostak
4 // Email:  artur@alice.phy.uct.ac.za | artursz@iafrica.com
5 //
6 ////////////////////////////////////////////////////////////////////////////////
7
8 #ifndef dHLT_DDL_L2_SIGNAL_RECEIVER_HPP
9 #define dHLT_DDL_L2_SIGNAL_RECEIVER_HPP
10
11 #include "BCMP/Receiver.hpp"
12 #include "EventID.hpp"
13
14 namespace dHLT
15 {
16 namespace DDL
17 {
18
19
20 class L2SignalReceiver : public BCMP::EventHandler
21 {
22 public:
23
24         L2SignalReceiver(const UShort port = 4900);
25         virtual ~L2SignalReceiver();
26
27         void Terminate() { terminate = true; };
28         
29         void Run();
30         
31         virtual void GotL2(const EventID eventid) = 0;
32         
33         virtual void OnMessage(
34                         const char* message, const UInt length,
35                         const System::Address& from
36                 );
37         
38 private:
39
40         bool terminate;
41         BCMP::Receiver receiver;
42 };
43
44
45 }; // DDL
46 }; // dHLT
47
48 #endif // dHLT_DDL_L2_SIGNAL_RECEIVER_HPP
49