From 9831478f756295aec1a93867d9f8e3a239e12f7b Mon Sep 17 00:00:00 2001 From: tmadlener Date: Thu, 6 Jul 2023 21:12:14 +0200 Subject: [PATCH 1/2] Workaround for coll metadata access in converters Giving public access to the metadata Frame should unblock parts of the Marlin wrapper developments / fixes --- k4FWCore/include/k4FWCore/PodioDataSvc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/k4FWCore/include/k4FWCore/PodioDataSvc.h b/k4FWCore/include/k4FWCore/PodioDataSvc.h index d6d5f074..3b8011a4 100644 --- a/k4FWCore/include/k4FWCore/PodioDataSvc.h +++ b/k4FWCore/include/k4FWCore/PodioDataSvc.h @@ -54,7 +54,7 @@ class PodioDataSvc : public DataSvc { /// Resets caches of reader and event store, increases event counter void endOfRead(); -private: + /// TODO: Make this private again after conversions have been properly solved podio::Frame& getMetaDataFrame() { return m_metadataframe; } private: From 5179d705af1aa39f165e93be04bcdc2ddc15c384 Mon Sep 17 00:00:00 2001 From: tmadlener Date: Thu, 6 Jul 2023 21:14:53 +0200 Subject: [PATCH 2/2] Move metadata handle name function upstream to podio Where it belongs --- k4FWCore/include/k4FWCore/MetaDataHandle.h | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/k4FWCore/include/k4FWCore/MetaDataHandle.h b/k4FWCore/include/k4FWCore/MetaDataHandle.h index eb1135df..6f6f87cb 100644 --- a/k4FWCore/include/k4FWCore/MetaDataHandle.h +++ b/k4FWCore/include/k4FWCore/MetaDataHandle.h @@ -11,14 +11,6 @@ #include -namespace k4FWCore { - - static std::string metaDataHandleDescriptor(const std::string& collectionName, const std::string& key) { - return collectionName + "__" + key; - } - -} // namespace k4FWCore - template class MetaDataHandle { public: MetaDataHandle(); @@ -88,7 +80,7 @@ template void MetaDataHandle::put(T value) { template std::string MetaDataHandle::fullDescriptor() { std::string full_descriptor; if (nullptr != m_dataHandle) { - full_descriptor = k4FWCore::metaDataHandleDescriptor(m_dataHandle->objKey(), m_descriptor); + full_descriptor = podio::collMetadataParamName(m_dataHandle->objKey(), m_descriptor); // remove the "/Event/" part of the collections' object key if in read mode if (m_mode == Gaudi::DataHandle::Reader) { full_descriptor.erase(0, 7);