Bug #92237 fixed as Barth suggested
[u/mrichter/AliRoot.git] / ZDC / PrintAlienChMapObject.C
CommitLineData
692715a3 1#if !defined(__CINT__) || defined(__MAKECINT__)
2#include <Riostream.h>
3#include <TSystem.h>
4#include <TRandom.h>
5#include <TROOT.h>
6#include <TStyle.h>
7#include <TCanvas.h>
8#include <TGraphErrors.h>
9#include <TGrid.h>
10#include <TFile.h>
11#include "AliCDBEntry.h"
12#include "AliCDBGrid.h"
13#include "AliCDBId.h"
14#include "AliCDBLocal.h"
15#include "AliCDBManager.h"
16#include "AliCDBMetaData.h"
17#include "AliCDBPath.h"
18#include "AliCDBRunRange.h"
19#include "AliCDBStorage.h"
20#include "AliDCSValue.h"
21#include "AliZDC.h"
22#include "AliZDCv3.h"
23#include "AliZDCPedestals.h"
24#include "AliZDCEnCalib.h"
25#include "AliZDCTowerCalib.h"
26#include "AliZDCChMap.h"
27#include "AliZDCLaserCalib.h"
28#include "AliZDCMBCalib.h"
29#include "AliZDCDataDCS.h"
30
31#endif
32
33
9577d217 34void PrintAlienChMapObject(TString histoFName="Run109690_999999999_v5_s0.root ",
692715a3 35 Int_t alienOCDB=1)
36{
37 TGrid::Connect("alien:",0,0,"t");
38
39 if (alienOCDB==1)histoFName = histoFName.Prepend("alien:///alice/data/2010/OCDB/ZDC/Calib/ChMap/");
9577d217 40 else if(alienOCDB==2) histoFName = histoFName.Prepend("alien:///alice/simulation/2008/v4-15-Release/Ideal/ZDC/Calib/ChMap/");
41 else if(alienOCDB==3) histoFName = histoFName.Prepend("alien:///alice/simulation/2008/v4-15-Release/Full/ZDC/Calib/ChMap/");
42 else if(alienOCDB==4) histoFName = histoFName.Prepend("alien:///alice/simulation/2008/v4-15-Release/Residual/ZDC/Calib/ChMap/");
692715a3 43 printf(" \n\n Printing object %s from alien OCDB \n\n",histoFName.Data());
44
45 TFile *f = TFile::Open(histoFName);
46 f->ls();
47 AliCDBEntry *entry = (AliCDBEntry*)f->Get("AliCDBEntry");
48 AliZDCChMap *calibdata = dynamic_cast<AliZDCChMap*> (entry->GetObject());
49 calibdata->Print("");
50
51}