k4SimGeant4
Loading...
Searching...
No Matches
MergeLayers.h
Go to the documentation of this file.
1#ifndef DETCOMPONENTS_MERGELAYERS_H
2#define DETCOMPONENTS_MERGELAYERS_H
3
4// GAUDI
5#include "Gaudi/Algorithm.h"
6
7// FCCSW
8#include "k4FWCore/DataHandle.h"
9class IGeoSvc;
10
11#include "DD4hep/IDDescriptor.h"
12
13// datamodel
14namespace edm4hep {
15class CalorimeterHitCollection;
16}
17
37class MergeLayers : public Gaudi::Algorithm {
38public:
39 explicit MergeLayers(const std::string&, ISvcLocator*);
40 virtual ~MergeLayers();
44 virtual StatusCode initialize() final;
48 virtual StatusCode execute(const EventContext&) const final;
53 virtual StatusCode finalize() final;
54
55private:
57 ServiceHandle<IGeoSvc> m_geoSvc;
59 mutable DataHandle<edm4hep::CalorimeterHitCollection> m_inHits{"hits/caloInHits", Gaudi::DataHandle::Reader, this};
61 mutable DataHandle<edm4hep::CalorimeterHitCollection> m_outHits{"hits/caloOutHits", Gaudi::DataHandle::Writer, this};
62 // Handle to the detector ID descriptor
63 dd4hep::IDDescriptor m_descriptor;
65 Gaudi::Property<std::string> m_readoutName{this, "readout", "", "Name of the detector readout"};
67 Gaudi::Property<std::string> m_idToMerge{this, "identifier", "", "Identifier to be merged"};
69 Gaudi::Property<std::string> m_volumeName{this, "volumeName", "", "Name (or its part) of the volume"};
71 Gaudi::Property<std::vector<uint>> m_listToMerge{
72 this, "merge", {}, "List with number of adjacent cells to be merged"};
74 Gaudi::Property<uint> m_debugPrint{this, "debugPrint", 10, "Maximum number of lines in debug output"};
75};
76#endif /* DETCOMPONENTS_MERGECELLS_H */
Merge layers (volume ids).
Definition MergeLayers.h:37
Gaudi::Property< std::string > m_volumeName
Name (or its part) of the volume.
Definition MergeLayers.h:69
Gaudi::Property< std::vector< uint > > m_listToMerge
List with number of adjacent cells to be merged.
Definition MergeLayers.h:71
Gaudi::Property< std::string > m_idToMerge
Identifier to be merged.
Definition MergeLayers.h:67
dd4hep::IDDescriptor m_descriptor
Definition MergeLayers.h:63
DataHandle< edm4hep::CalorimeterHitCollection > m_inHits
Handle for the EDM Hits to be read.
Definition MergeLayers.h:59
virtual ~MergeLayers()
Definition MergeLayers.cpp:25
Gaudi::Property< std::string > m_readoutName
Name of the detector readout.
Definition MergeLayers.h:65
virtual StatusCode finalize() final
Finalize.
Definition MergeLayers.cpp:112
ServiceHandle< IGeoSvc > m_geoSvc
Pointer to the geometry service.
Definition MergeLayers.h:57
virtual StatusCode execute(const EventContext &) const final
Execute.
Definition MergeLayers.cpp:64
virtual StatusCode initialize() final
Initialize.
Definition MergeLayers.cpp:27
MergeLayers(const std::string &, ISvcLocator *)
Definition MergeLayers.cpp:20
DataHandle< edm4hep::CalorimeterHitCollection > m_outHits
Handle for the EDM Hits to be written.
Definition MergeLayers.h:61
Gaudi::Property< uint > m_debugPrint
Maximum number of lines in debug output.
Definition MergeLayers.h:74
Definition EventInformation.h:10