Belle II Software development
StorageSerializer.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 STORAGE_OUTPUT_H
10#define STORAGE_OUTPUT_H
11
12#include <framework/core/Module.h>
13#include <framework/pcore/MsgHandler.h>
14#include <framework/pcore/DataStoreStreamer.h>
15
16#include <daq/storage/SharedEventBuffer.h>
17
18#include <string>
19
20namespace Belle2 {
28
29 // Public functions
30 public:
31
35
37 void initialize() override;
38
40 void beginRun() override;
41 void event() override;
42 void endRun() override;
43 void terminate() override;
44
45 // Data members
46 private:
49
52
55
57 std::string m_obuf_name;
58 int m_obuf_size;
59 SharedEventBuffer m_obuf;
60
62 unsigned int m_count;
63 unsigned int m_count_0;
64 int m_expno;
65 int m_runno;
66 unsigned long long m_nbyte;
67 int m_nodeid;
68
69 private:
70 int writeStreamerInfos();
71
72 };
74} // end namespace Belle2
75
76#endif
Stream/restore DataStore objects to/from EvtMessage.
Base class for Modules.
Definition: Module.h:72
A class to encode/decode an EvtMessage.
Definition: MsgHandler.h:103
Class definition for the output module of Sequential ROOT I/O.
DataStoreStreamer * m_streamer
DataStoreStreamer.
std::string m_obuf_name
Ring Buffer to dump sampled output stream.
void initialize() override
Module functions to be called from main process.
unsigned int m_count
Exp number, Run number.
StorageSerializerModule()
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.
MsgHandler * m_msghandler
Messaage handler.
void beginRun() override
Module functions to be called from event process.
int m_compressionLevel
Compression level.
Abstract base class for different kinds of events.