k4SimGeant4
Loading...
Searching...
No Matches
SimG4SmearGenParticles.h
Go to the documentation of this file.
1#ifndef SIMG4COMPONENTS_G4SMEARGENPARTICLES_H
2#define SIMG4COMPONENTS_G4SMEARGENPARTICLES_H
3
4// Gaudi
5#include "Gaudi/Algorithm.h"
6#include "GaudiKernel/ToolHandle.h"
7
8// FCCSW
9#include "k4FWCore/DataHandle.h"
12
13// datamodel
14namespace edm4hep {
15class MCParticleCollection;
16}
17
25class SimG4SmearGenParticles : public Gaudi::Algorithm {
26 public:
27 SimG4SmearGenParticles(const std::string& aName, ISvcLocator* svcLoc);
31 StatusCode initialize();
35 StatusCode finalize();
41 StatusCode execute(const EventContext&) const;
42
43 private:
45 mutable DataHandle<edm4hep::MCParticleCollection> m_inParticles{"GenParticles", Gaudi::DataHandle::Reader, this};
47 mutable DataHandle<edm4hep::MCParticleCollection> m_particles{"SimParticlesSmeared", Gaudi::DataHandle::Writer, this};
49 mutable ToolHandle<ISimG4ParticleSmearTool> m_smearTool{"SimG4ParticleSmearRootFile", this};
51 Gaudi::Property<bool> m_simTracker{this, "simulateTracker", true};
52};
53
54#endif /* SIMG4COMPONENTS_G4SAVESMEAREDPARTICLES_H */
Smear 'generated' (smeared) particles.
Definition SimG4SmearGenParticles.h:25
DataHandle< edm4hep::MCParticleCollection > m_particles
Handle for the particles to be written.
Definition SimG4SmearGenParticles.h:47
StatusCode execute(const EventContext &) const
Save the data output.
Definition SimG4SmearGenParticles.cpp:35
StatusCode finalize()
Finalize.
Definition SimG4SmearGenParticles.cpp:83
ToolHandle< ISimG4ParticleSmearTool > m_smearTool
Handle for the calorimeter cells noise tool.
Definition SimG4SmearGenParticles.h:49
SimG4SmearGenParticles(const std::string &aName, ISvcLocator *svcLoc)
Definition SimG4SmearGenParticles.cpp:18
Gaudi::Property< bool > m_simTracker
Flag to decide on wether to only smear and write out charged particles.
Definition SimG4SmearGenParticles.h:51
DataHandle< edm4hep::MCParticleCollection > m_inParticles
Handle for the particles to be written
Definition SimG4SmearGenParticles.h:45
StatusCode initialize()
Initialize.
Definition SimG4SmearGenParticles.cpp:24
Definition EventInformation.h:10