Belle II Software  release-06-01-15
ReceiveEvent.h
1 /**************************************************************************
2  * basf2 (Belle II Analysis Software Framework) *
3  * Author: The Belle II Collaboration *
4  * *
5  * See git log for contributors and copyright holders. *
6  * This file is licensed under LGPL-3.0, see LICENSE.md. *
7  **************************************************************************/
8 
9 #ifndef RECEIVE_EVENT_MODULE_H
10 #define RECEIVE_EVENT_MODULE_H
11 
12 #include <framework/core/Module.h>
13 #include <daq/dataflow/EvtSocket.h>
14 
15 #include <string>
16 
17 #include <framework/pcore/DataStoreStreamer.h>
18 
19 namespace Belle2 {
27  class ReceiveEventModule : public Module {
28 
29  // Public functions
30  public:
31 
34  virtual ~ReceiveEventModule();
35 
37  virtual void initialize();
38 
40  virtual void beginRun();
41  virtual void event();
42  virtual void endRun();
43  virtual void terminate();
44 
45  // Data members
46  private:
47 
49  std::string m_host;
50  int m_port;
51 
54 
57 
60 
62  int m_nrecv;
63 
64  };
65 
67 } // end namespace Belle2
68 
69 #endif // MODULEHELLO_H
Stream/restore DataStore objects to/from EvtMessage.
Base class for Modules.
Definition: Module.h:72
A class definition of an input module for Sequential ROOT I/O.
Definition: ReceiveEvent.h:27
virtual void event()
This method is the core of the module.
Definition: ReceiveEvent.cc:83
DataStoreStreamer * m_streamer
DataStoreStreamer.
Definition: ReceiveEvent.h:56
virtual void initialize()
Module functions to be called from main process.
Definition: ReceiveEvent.cc:49
virtual void beginRun()
Module functions to be called from event process.
Definition: ReceiveEvent.cc:77
EvtSocketSend * m_recv
Reciever Socket.
Definition: ReceiveEvent.h:53
virtual void terminate()
This method is called at the end of the event processing.
virtual void endRun()
This method is called if the current run ends.
std::string m_host
Receiver Port.
Definition: ReceiveEvent.h:49
ReceiveEventModule()
Constructor / Destructor.
Definition: ReceiveEvent.cc:29
int m_nrecv
No. of sent events.
Definition: ReceiveEvent.h:62
int m_compressionLevel
Compression Level.
Definition: ReceiveEvent.h:59
Abstract base class for different kinds of events.