Belle II Software  release-08-01-10
RemoveMCParticlesModule.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 #include <mdst/dataobjects/MCParticleGraph.h>
13 #include <string>
14 
15 namespace Belle2 {
30 
31  public:
32 
38 
41 
43  virtual void initialize() override;
44 
46  virtual void event() override;
47 
49  virtual void terminate() override;
50 
55  void applyCuts(const MCParticle& particle, bool cut = false);
56 
57  protected:
58  //Parameters
59  std::string m_particleList;
60  double m_minZ;
61  double m_maxZ;
62  double m_minR;
63  double m_maxR;
64  double m_minTheta;
65  double m_maxTheta;
66  double m_minPt;
67  double m_maxPt;
69  std::vector<int> m_pdgCodes;
72  };
73 
74 
76 } // end namespace Belle2
77 
78 
Class to build, validate and sort a particle decay chain.
A Class to store the Monte Carlo particle information.
Definition: MCParticle.h:32
Base class for Modules.
Definition: Module.h:72
The RemoveMCParticles module.
void applyCuts(const MCParticle &particle, bool cut=false)
Apply cuts on a Particle and call for all daugthers recursively.
double m_maxTheta
Maximum Theta value of particles to keep.
virtual void initialize() override
Initializes the module.
virtual void event() override
Method is called for each event.
double m_minR
Minimum Rphi value of particles to keep.
virtual void terminate() override
Terminates the module.
double m_maxZ
Maximum Z value of particles to keep.
bool m_alsoChildren
If true, also remove all children of a particle if it fails any cut.
double m_minZ
Minimum Z value of particles to keep.
double m_minTheta
Minimum Theta value of particles to keep.
double m_minPt
Minimum Pt value of particles to keep.
virtual ~RemoveMCParticlesModule()
Destructor.
std::string m_particleList
Name of the MCParticle collection to work on.
std::vector< int > m_pdgCodes
List of pdgCodes wo apply cuts on.
double m_maxPt
Maximum Pt value of particles to keep.
MCParticleGraph m_mpg
ParticleGraph used for reformatting MCParticle collection.
double m_maxR
Maximum Rphi value of particles to keep.
Abstract base class for different kinds of events.