From f5ea7ce2b63f033d2ffa02754142b5e97c7ea6a3 Mon Sep 17 00:00:00 2001 From: richterm Date: Tue, 6 Jul 2010 09:15:53 +0000 Subject: [PATCH] allow merging of non-std objects which are not a collection --- HLT/rec/AliHLTEsdManagerImplementation.cxx | 15 ++++++++++++++- HLT/rec/AliHLTEsdManagerImplementation.h | 7 ++++++- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/HLT/rec/AliHLTEsdManagerImplementation.cxx b/HLT/rec/AliHLTEsdManagerImplementation.cxx index 788b6de07d1..23ced4c4fb1 100644 --- a/HLT/rec/AliHLTEsdManagerImplementation.cxx +++ b/HLT/rec/AliHLTEsdManagerImplementation.cxx @@ -728,8 +728,11 @@ int AliHLTEsdManagerImplementation::Merge(AliESDEvent* pTgt, AliESDEvent* pSrc) } else if (pSrcObject->IsA()==AliESDACORDE::Class()) { AliESDACORDE* pESDACORDE=dynamic_cast(pSrcObject); copy=(pESDACORDE && false); // have to find an easy valid condition + } else if (!AliHLTESDEventHelper::IsStdContent(name)) { + // this is likely to be ok as long as it is not any object of the std content. + copy=true; } else { - HLTError("no merging implemented for object %s, omitting", name.Data()); + HLTError("no merging implemented for object %s, omitting", name.Data()); } if (copy) { //pSrcObject->Print(); @@ -795,3 +798,13 @@ int AliHLTEsdManagerImplementation::Merge(AliESDEvent* pTgt, AliESDEvent* pSrc) } return iResult; } + +bool AliHLTEsdManagerImplementation::AliHLTESDEventHelper::IsStdContent(const char* key) +{ + // check if the key denotes a std object + TString needle=key; + for (int i=0; i -class AliESDEvent; class TTree; class TFile; @@ -98,6 +98,11 @@ class AliHLTEsdManagerImplementation : public AliHLTEsdManager { */ static TTree* EmbedIntoTree(AliESDEvent* pESD, const char* name="esdTree", const char* title="Tree with HLT ESD objects"); + class AliHLTESDEventHelper : public AliESDEvent { + public: + static bool IsStdContent(const char* key); + }; + protected: private: -- 2.43.0