diff --git a/Detector/DetComponents/src/RedoSegmentation.h b/Detector/DetComponents/src/RedoSegmentation.h index 659a808..1ac3c52 100644 --- a/Detector/DetComponents/src/RedoSegmentation.h +++ b/Detector/DetComponents/src/RedoSegmentation.h @@ -17,6 +17,7 @@ // EDM4hep #include "edm4hep/CalorimeterHitCollection.h" #include "edm4hep/SimCalorimeterHitCollection.h" +#include "edm4hep/Constants.h" /** @class RedoSegmentation Detector/DetComponents/src/RedoSegmentation.h RedoSegmentation.h * @@ -61,15 +62,12 @@ class RedoSegmentation : public GaudiAlgorithm { /// Handle for the EDM positioned hits to be read DataHandle m_inHits{ "hits/caloInHits", Gaudi::DataHandle::Reader, this}; - /// Handle for the input hits cell id encoding - MetaDataHandle m_inHitsCellIDEncoding{ - m_inHits,"CellIDEncodingString", Gaudi::DataHandle::Reader}; /// Handle for the EDM hits to be written DataHandle m_outHits{ "hits/caloOutHits", Gaudi::DataHandle::Writer, this}; - /// Handle for the output hits cell id encoding + /// Handle for the output hits cell id encoding. MetaDataHandle m_outHitsCellIDEncoding{ - m_outHits,"CellIDEncodingString", Gaudi::DataHandle::Writer}; + m_outHits, edm4hep::CellIDEncoding, Gaudi::DataHandle::Writer}; /// New segmentation dd4hep::DDSegmentation::Segmentation* m_segmentation; int m_segmentationType; // use enum instead? defined in some namespace? diff --git a/SimG4Components/src/SimG4SaveCalHits.h b/SimG4Components/src/SimG4SaveCalHits.h index 8580772..95a236f 100644 --- a/SimG4Components/src/SimG4SaveCalHits.h +++ b/SimG4Components/src/SimG4SaveCalHits.h @@ -16,6 +16,7 @@ // EDM4hep #include "edm4hep/SimCalorimeterHitCollection.h" +#include "edm4hep/Constants.h" /** @class SimG4SaveCalHits SimG4Components/src/SimG4SaveCalHits.h SimG4SaveCalHits.h * @@ -68,7 +69,7 @@ class SimG4SaveCalHits : public GaudiTool, virtual public ISimG4SaveOutputTool { "CaloHits", Gaudi::DataHandle::Writer, this}; /// Output handle for cell ID encoding string MetaDataHandle m_cellIDEncoding{ - m_caloHits, "CellIDEncodingString", Gaudi::DataHandle::Writer}; + m_caloHits, edm4hep::CellIDEncoding, Gaudi::DataHandle::Writer}; /// Name of the readouts (hits collections) to save, deprecated Gaudi::Property> m_readoutNames{ this, "readoutNames", {}, "[Deprecated] Names of the readouts (hits collections) to save"}; diff --git a/SimG4Components/src/SimG4SaveTrackerHits.h b/SimG4Components/src/SimG4SaveTrackerHits.h index 1c304e3..d40d9d4 100644 --- a/SimG4Components/src/SimG4SaveTrackerHits.h +++ b/SimG4Components/src/SimG4SaveTrackerHits.h @@ -16,6 +16,7 @@ // EDM4hep #include "edm4hep/SimTrackerHitCollection.h" +#include "edm4hep/Constants.h" /** @class SimG4SaveTrackerHits SimG4Components/src/SimG4SaveTrackerHits.h SimG4SaveTrackerHits.h * @@ -69,7 +70,7 @@ class SimG4SaveTrackerHits : public GaudiTool, virtual public ISimG4SaveOutputTo "TrackerHits", Gaudi::DataHandle::Writer, this}; /// Output handle for cell ID encoding string MetaDataHandle m_cellIDEncoding { - m_trackHits, "CellIDEncodingString", Gaudi::DataHandle::Writer}; + m_trackHits, edm4hep::CellIDEncoding, Gaudi::DataHandle::Writer}; /// Names of the readouts (hits collections) to save, deprecated Gaudi::Property> m_readoutNames { this, "readoutNames", {}, "[Deprecated] Name of the readouts (hits collections) to save"};