diff --git a/ForwardDetectors/ZDC/ZdcAnalysis/CMakeLists.txt b/ForwardDetectors/ZDC/ZdcAnalysis/CMakeLists.txt index d1a0e7097e4cb0578f47e2557469ca43093f30f7..055ba7d022e2b3d800c81e12fd87ff8ad591ab19 100644 --- a/ForwardDetectors/ZDC/ZdcAnalysis/CMakeLists.txt +++ b/ForwardDetectors/ZDC/ZdcAnalysis/CMakeLists.txt @@ -22,5 +22,6 @@ atlas_add_library (ZdcAnalysisLib Root/*.cxx PUBLIC_HEADERS ZdcAnalysis PRIVATE_INCLUDE_DIRS ${ROOT_INCLUDE_DIRS} + LINK_LIBRARIES AsgDataHandlesLib PRIVATE_LINK_LIBRARIES ${ROOT_LIBRARIES} AsgTools xAODForward xAODTrigL1Calo xAODEventInfo PathResolver ) diff --git a/ForwardDetectors/ZDC/ZdcAnalysis/Root/ZdcAnalysisTool.cxx b/ForwardDetectors/ZDC/ZdcAnalysis/Root/ZdcAnalysisTool.cxx index 52ab89e72fef4e277670ba862a81fa5e42c71aa3..716bd5839c8a09b2f212df13ef4dfcb4a5352abb 100644 --- a/ForwardDetectors/ZDC/ZdcAnalysis/Root/ZdcAnalysisTool.cxx +++ b/ForwardDetectors/ZDC/ZdcAnalysis/Root/ZdcAnalysisTool.cxx @@ -11,6 +11,8 @@ #include <sstream> #include <memory> #include <xAODForward/ZdcModuleAuxContainer.h> +#include <AsgDataHandles/ReadHandle.h> +#include <AsgDataHandles/WriteHandle.h> #include "PathResolver/PathResolver.h" namespace ZDC @@ -19,8 +21,6 @@ namespace ZDC ZdcAnalysisTool::ZdcAnalysisTool(const std::string& name) : asg::AsgTool(name), m_name(name), m_writeAux(false), m_runNumber(0), m_lumiBlock(0), - m_eventInfoKey("EventInfo"), - m_ZdcModuleWriteKey("ZdcSums"), m_splines{{{{0,0,0,0}},{{0,0,0,0}}}}, m_zdcTriggerEfficiency(0) { @@ -28,8 +28,6 @@ namespace ZDC declareInterface<IZdcAnalysisTool>(this); #endif - declareProperty("EventInfoKey", m_eventInfoKey, "Location of the event info."); - declareProperty("ZdcModuleWriteKey", m_ZdcModuleWriteKey, "Output location of ZDC reprocessed data"); declareProperty("Configuration", m_configuration = "PbPb2015"); declareProperty("FlipEMDelay",m_flipEMDelay=false); declareProperty("LowGainOnly",m_lowGainOnly=false); diff --git a/ForwardDetectors/ZDC/ZdcAnalysis/ZdcAnalysis/ZdcAnalysisTool.h b/ForwardDetectors/ZDC/ZdcAnalysis/ZdcAnalysis/ZdcAnalysisTool.h index 8d944608d957e26b6610344dd86b447c87f78132..ef571486a5bfb2cb50f94e23f709ff2e227a4b15 100644 --- a/ForwardDetectors/ZDC/ZdcAnalysis/ZdcAnalysis/ZdcAnalysisTool.h +++ b/ForwardDetectors/ZDC/ZdcAnalysis/ZdcAnalysis/ZdcAnalysisTool.h @@ -5,6 +5,8 @@ #ifndef ZDCANALYSIS_ZDCANALYSISTOOL_H #define ZDCANALYSIS_ZDCANALYSISTOOL_H +#include "AsgDataHandles/ReadHandleKey.h" +#include "AsgDataHandles/WriteHandleKey.h" #include "AsgTools/AsgTool.h" #include "xAODEventInfo/EventInfo.h" #include "xAODForward/ZdcModuleContainer.h" @@ -93,8 +95,13 @@ class ZdcAnalysisTool : public virtual IZdcAnalysisTool, public asg::AsgTool // internal functions TF1* m_tf1SincInterp; - SG::ReadHandleKey<xAOD::EventInfo> m_eventInfoKey; - SG::WriteHandleKey<xAOD::ZdcModuleContainer> m_ZdcModuleWriteKey; + SG::ReadHandleKey<xAOD::EventInfo> m_eventInfoKey { + this, "EventInfoKey", "EventInfo", + "Location of the event info."}; + SG::WriteHandleKey<xAOD::ZdcModuleContainer> m_ZdcModuleWriteKey { + this, "ZdcModuleWriteKey", "ZdcSums", + "Output location of ZDC reprocessed data"}; + ; bool m_flipEMDelay; bool m_lowGainOnly; bool m_combineDelay;