Belle II Software development
B2BIIMCParticlesMonitorModule.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// File : B2BIIMCParticlesMonitorModule.h
10// Description : A module to plot MCParticles monitor histograms in basf2
11//
12//-
13
14#pragma once
15
16#include <framework/core/HistoModule.h> // <- Substitution of HistoModule.h
17#include "TH1F.h"
18
19namespace Belle2 {
26 class B2BIIMCParticlesMonitorModule : public HistoModule { // <- derived from HistoModule class
27
28 public:
29
34
36 virtual void initialize() override;
38 virtual void beginRun() override;
40 virtual void event() override;
42 virtual void endRun() override;
44 virtual void terminate() override;
45
47 virtual void defineHisto() override;
48
49 private:
50 TH1F* mcPDG{nullptr};
51 TH1F* mcM{nullptr};
52 TH1F* mcPx{nullptr};
53 TH1F* mcPy{nullptr};
54 TH1F* mcPz{nullptr};
55 TH1F* mcE{nullptr};
56 TH1F* mcVx{nullptr};
57 TH1F* mcVy{nullptr};
58 TH1F* mcVz{nullptr};
59 TH1F* mcPiPlusMother{nullptr};
60 TH1F* mcPiMinusMother{nullptr};
61 TH1F* mcPi0Mother{nullptr};
62 TH1F* mcNDau{nullptr};
64 };
66}
Declaration of class B2BIIMCParticlesMonitor.
TH1F * mcPi0Mother
histogram PDG codes of mother particles of pi0's
virtual void initialize() override
Initialize the module.
TH1F * mcPDG
histogram PDG values of MC Particles
virtual void event() override
Called for each event.
virtual void endRun() override
Called when the current run finished.
virtual void terminate() override
Terminates the module.
virtual void beginRun() override
Called when a new run is started.
TH1F * mcPiMinusMother
histogram PDG codes of mother particles of negative pions
TH1F * mcPiPlusMother
histogram PDG codes of mother particles of positive pions
TH1F * mcNDau
histogram number of daughter particles of all particles
virtual void defineHisto() override
function to define histograms
HistoModule.h is supposed to be used instead of Module.h for the modules with histogram definitions t...
Definition: HistoModule.h:29
Abstract base class for different kinds of events.