Macro to get the CDB information stored in the ESD file (Alberto)
authorhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 21 Nov 2007 14:04:55 +0000 (14:04 +0000)
committerhristov <hristov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 21 Nov 2007 14:04:55 +0000 (14:04 +0000)
macros/GetCDBInfoFromESD.C [new file with mode: 0644]

diff --git a/macros/GetCDBInfoFromESD.C b/macros/GetCDBInfoFromESD.C
new file mode 100644 (file)
index 0000000..7a47626
--- /dev/null
@@ -0,0 +1,19 @@
+// Simple example how to get CDB information stored in the ESD:
+// - The list of parameters got from OCDB during reconstruction (cdbList)
+// - The map of storages (default + specific) activated (cdbMap)
+//
+// author: alberto.colla@cern.ch
+
+void GetCDBInfoFromESD(){
+
+       TFile * f = new TFile("AliESDs.root");
+
+       TTree* tree = f->Get("esdTree");
+       TList* l = tree->GetUserInfo();
+
+       TList* ids = l->FindObject("cdbList");
+       ids->Print();
+
+       TMap* storages = l->FindObject("cdbMap");
+       storages->Print();
+}