]> git.uio.no Git - u/mrichter/AliRoot.git/blob - ZDC/MakeZDCRecoParam.C
1.The QA data created on demand according to the event species at filling time. 2...
[u/mrichter/AliRoot.git] / ZDC / MakeZDCRecoParam.C
1 void MakeZDCRecoParam(Int_t type=0){
2 //========================================================================
3 //
4 // Steering macro to create and store in OCDB
5 //       ZDC reconstruction parameters
6 //
7 // Contact: chiara.oppedisano@to.infn.it
8 //
9 //========================================================================
10
11   AliCDBManager* cdb = AliCDBManager::Instance();
12   //if(!cdb->IsDefaultStorageSet()) cdb->SetDefaultStorage("local://OCDB");
13   cdb->SetDefaultStorage("local://$ALICE_ROOT/OCDB");
14   
15   AliZDCRecoParam *zdcRecoParam = 0;
16   //
17   switch(type) {
18   case 0:
19     zdcRecoParam = (AliZDCRecoParampp*) AliZDCRecoParampp::GetppRecoParam();
20     zdcRecoParam->SetBeamEnergy(5000.); 
21     break;
22   case 1:
23     zdcRecoParam = (AliZDCRecoParamPbPb*) AliZDCRecoParamPbPb::GetPbPbRecoParam();
24     break;
25   case default:
26     printf("Event type not implemented\n");
27     return;
28     break;
29   }
30   //
31   // save in CDB storage
32   AliCDBMetaData *md= new AliCDBMetaData();
33   md->SetResponsible("Chiara Oppedisano");
34   md->SetComment("Reconstruction parameters for ZDC");
35   md->SetAliRootVersion(gSystem->Getenv("ARVERSION"));
36   md->SetBeamPeriod(0);
37   md->SetObjectClassName("AliZDCRecoParam");
38   AliCDBId id("ZDC/Calib/RecoParam",0,AliCDBRunRange::Infinity());
39   AliCDBManager::Instance()->GetDefaultStorage()->Put(zdcRecoParam,id, md);
40
41 }