From 13cbb0ec339ad8628cdaf7ca2a069cfec1e6963b Mon Sep 17 00:00:00 2001
From: Bill Balunas <bill.balunas@cern.ch>
Date: Mon, 12 Aug 2019 15:49:33 +0200
Subject: [PATCH] Allow user to configure voronoi area decoration name

---
 .../Jet/JetMomentTools/JetMomentTools/JetVoronoiMomentsTool.h  | 1 +
 .../Jet/JetMomentTools/src/JetVoronoiMomentsTool.cxx           | 3 ++-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/Reconstruction/Jet/JetMomentTools/JetMomentTools/JetVoronoiMomentsTool.h b/Reconstruction/Jet/JetMomentTools/JetMomentTools/JetVoronoiMomentsTool.h
index 4331de3aa10f..add8ec9baf70 100644
--- a/Reconstruction/Jet/JetMomentTools/JetMomentTools/JetVoronoiMomentsTool.h
+++ b/Reconstruction/Jet/JetMomentTools/JetMomentTools/JetVoronoiMomentsTool.h
@@ -49,6 +49,7 @@ private:
   float m_y_max;
 
   std::string m_jetContainerName;
+  std::string m_decorationName;
   SG::WriteDecorHandleKey<xAOD::JetContainer> m_voronoiAreaKey;
 
 };
diff --git a/Reconstruction/Jet/JetMomentTools/src/JetVoronoiMomentsTool.cxx b/Reconstruction/Jet/JetMomentTools/src/JetVoronoiMomentsTool.cxx
index 2cd746e31d33..3ba7ce07a4e1 100644
--- a/Reconstruction/Jet/JetMomentTools/src/JetVoronoiMomentsTool.cxx
+++ b/Reconstruction/Jet/JetMomentTools/src/JetVoronoiMomentsTool.cxx
@@ -32,8 +32,9 @@ JetVoronoiMomentsTool::JetVoronoiMomentsTool(const std::string& name)
     declareProperty("AreaYmin",m_y_min);
     declareProperty("AreaYmax",m_y_max);
     declareProperty("JetContainer", m_jetContainerName);
+    declareProperty("DecorationName", m_decorationName = "VoronoiArea");
 
-    m_voronoiAreaKey = m_jetContainerName + ".VoronoiArea";
+    m_voronoiAreaKey = m_jetContainerName + "." + m_decorationName;
 }
 
 StatusCode JetVoronoiMomentsTool::initialize() {
-- 
GitLab