Belle II Software development
Ds2RbufModule.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 DS2RBUFMODULE_H
10#define DS2RBUFMODULE_H
11
12#include <framework/core/Module.h>
13#include <framework/pcore/RingBuffer.h>
14
15#include <framework/pcore/DataStoreStreamer.h>
16
17#include <string>
18
19#define RBUFSIZE 100000000
20
21namespace Belle2 {
29 class Ds2RbufModule : public Module {
30
31 // Public functions
32 public:
33
36 virtual ~Ds2RbufModule();
37
39 void initialize() override;
40
42 void beginRun() override;
43 void event() override;
44 void endRun() override;
45 void terminate() override;
46
47 // Data members
48 private:
49
52
54 std::string m_rbufname;
55 RingBuffer* m_rbuf;
56
59
62
64 std::vector<std::string> m_saveobjs;
65
66 };
67
69} // end namespace Belle2
70
71#endif // MODULEHELLO_H
Stream/restore DataStore objects to/from EvtMessage.
A class definition of an input module for Sequential ROOT I/O.
Definition: Ds2RbufModule.h:29
DataStoreStreamer * m_streamer
DataStore streamer.
Definition: Ds2RbufModule.h:58
void initialize() override
Module functions to be called from main process.
Ds2RbufModule()
Constructor / Destructor.
void event() override
This method is the core of the module.
void endRun() override
This method is called if the current run ends.
void terminate() override
This method is called at the end of the event processing.
void beginRun() override
Module functions to be called from event process.
int m_nsent
No. of sent events.
Definition: Ds2RbufModule.h:61
std::vector< std::string > m_saveobjs
List of objects to be transferred.
Definition: Ds2RbufModule.h:64
int m_compressionLevel
Compression parameter.
Definition: Ds2RbufModule.h:51
std::string m_rbufname
RingBuffer ID.
Definition: Ds2RbufModule.h:54
Base class for Modules.
Definition: Module.h:72
Class to manage a Ring Buffer placed in an IPC shared memory.
Definition: RingBuffer.h:39
Abstract base class for different kinds of events.