ATLAS Offline Software
Loading...
Searching...
No Matches
HepMCTruthReader.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef HEPMCTRUTHREADER_H
6#define HEPMCTRUTHREADER_H
7
9
14
16
17
21public:
22
24 HepMCTruthReader(const std::string& name, ISvcLocator* svcLoc);
25
27 virtual StatusCode initialize();
28
30 virtual StatusCode execute(const EventContext& ctx) const;
31
32
33private:
34
37 this, "HepMCContainerKey", "GEN_EVENT", "The input McEvenCollection"};
38
40 Gaudi::Property<bool> m_do4momPtEtaPhi{this, "Do4momPtEtaPhi", false};
41
42 static void printEvent(const HepMC::GenEvent* evt, bool do4momPtEtaPhi);
43 static void printVertex(const HepMC::ConstGenVertexPtr& vtx, bool do4momPtEtaPhi );
44 static void printParticle(const HepMC::ConstGenParticlePtr& part, bool do4momPtEtaPhi);
45
46}; // class HepMCTruthReader
47
48
49
50#endif // HEPMCTRUTHREADER_H
Property holding a SG store/key/clid from which a ReadHandle is made.
An algorithm that can be simultaneously executed in multiple threads.
static void printVertex(const HepMC::ConstGenVertexPtr &vtx, bool do4momPtEtaPhi)
virtual StatusCode initialize()
Function initialising the algorithm.
HepMCTruthReader(const std::string &name, ISvcLocator *svcLoc)
Regular algorithm constructor.
Gaudi::Property< bool > m_do4momPtEtaPhi
Flag to printout in pt,eta,phi instead of px,py,pz.
static void printEvent(const HepMC::GenEvent *evt, bool do4momPtEtaPhi)
SG::ReadHandleKey< McEventCollection > m_hepMCContainerKey
The key of the input HepMC truth container.
static void printParticle(const HepMC::ConstGenParticlePtr &part, bool do4momPtEtaPhi)
virtual StatusCode execute(const EventContext &ctx) const
Function executing the algorithm.
Property holding a SG store/key/clid from which a ReadHandle is made.
const GenParticle * ConstGenParticlePtr
Definition GenParticle.h:38
const HepMC::GenVertex * ConstGenVertexPtr
Definition GenVertex.h:60