AliPhysics  6fe3466 (6fe3466)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
TestFCM.C
Go to the documentation of this file.
1 const char* filename = "corr.root";
2 
3 void
5 {
6  AliForwardCorrectionManagerOADB& fcm =
7  AliForwardCorrectionManagerOADB::Instance();
8  fcm.Init(0, 1, 900, 5);
9  fcm.Print("R");
10 
11  TFile* file = TFile::Open(filename, "RECREATE");
12  fcm.Write();
13  delete file;
14 }
15 
16 void
18 {
19  TFile* file = TFile::Open(filename, "READ");
20  file->Get("forwardCorrections");
21 
22  AliForwardCorrectionManagerOADB& fcm =
23  AliForwardCorrectionManagerOADB::Instance();
24  // fcm.Init(0, 1, 900, 5);
25  fcm.Print("R");
26 }
27 
28 
29 void
30 TestFCM(bool write=true)
31 {
32  gROOT->Macro("$ALICE_PHYSICS/PWGLF/FORWARD/analysis2/scripts/LoadLibs.C");
33 
34  if (write) WriteFCM();
35  else ReadFCM();
36 }
37 
38 
const char * filename
Definition: TestFCM.C:1
void ReadFCM()
Definition: TestFCM.C:17
void TestFCM(bool write=true)
Definition: TestFCM.C:30
TFile * file
void WriteFCM()
Definition: TestFCM.C:4