Belle II Software development
HepevtOutputModule.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#pragma once
10
11#include <framework/core/Module.h>
12
13#include <fstream>
14#include <string>
15
16namespace Belle2 {
26 class HepevtOutputModule : public Module {
27
28 public:
29
35
38
40 virtual void initialize() override;
41
43 virtual void event() override;
44
46 virtual void terminate() override;
47
48
49 protected:
50
51 //Parameter
52 std::string m_filename;
57 //Variables
58 std::ofstream m_fileStream;
60 };
61
63} // end namespace Belle2
64
65
The HepevtOutput module.
bool m_mirrorPz
If the directions of HER and LER are switched, mirror Pz.
virtual void initialize() override
Initializes the module.
bool m_storeVirtualParticles
Flag which specifies if virtual particles are stored in the HEPEvt file.
virtual void event() override
Method is called for each event.
virtual void terminate() override
Terminates the module.
bool m_fullFormat
Flag which specifies if the full HepEvt format should be written (true), or a compact format (false).
virtual ~HepevtOutputModule()
Destructor.
std::ofstream m_fileStream
The text file stream.
std::string m_filename
The output filename.
Base class for Modules.
Definition: Module.h:72
Abstract base class for different kinds of events.