]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Use TFile::Open in all AddTask macros
authorprino <prino@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 1 Feb 2012 14:23:57 +0000 (14:23 +0000)
committerprino <prino@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 1 Feb 2012 14:23:57 +0000 (14:23 +0000)
14 files changed:
PWGHF/vertexingHF/macros/AddTaskCFMultiVarMultiStep.C
PWGHF/vertexingHF/macros/AddTaskCFVertexingHF.C
PWGHF/vertexingHF/macros/AddTaskCFVertexingHF3Prong.C
PWGHF/vertexingHF/macros/AddTaskCFVertexingHF3ProngLc.C
PWGHF/vertexingHF/macros/AddTaskCFVertexingHFCascade.C
PWGHF/vertexingHF/macros/AddTaskD0Mass.C
PWGHF/vertexingHF/macros/AddTaskDStarJets.C
PWGHF/vertexingHF/macros/AddTaskDStarSpectra.C
PWGHF/vertexingHF/macros/AddTaskDplus.C
PWGHF/vertexingHF/macros/AddTaskDs.C
PWGHF/vertexingHF/macros/AddTaskHFQA.C
PWGHF/vertexingHF/macros/AddTaskLambdac.C
PWGHF/vertexingHF/macros/AddTaskSelectHF4Prong.C
PWGHF/vertexingHF/macros/AddTaskSignificance.C

index 2ea16ae56d6d4cb57020f4fb2d8c747dab06ed16..a85a32e670e60e2f02d3203b257f3e67f327262e 100644 (file)
@@ -50,7 +50,7 @@ AliCFHeavyFlavourTaskMultiVarMultiStep *AddTaskCFMultiVarMultiStep(const char* c
 
        printf("Adding CF task using cuts from file %s\n",cutFile);
        
-       TFile* fileCuts = new TFile(cutFile);
+       TFile* fileCuts = TFile::Open(cutFile);
        AliRDHFCutsD0toKpi *cutsD0toKpi = (AliRDHFCutsD0toKpi*)fileCuts->Get("D0toKpiCutsStandard");
        
        // check that the fKeepD0fromB flag is set to true when the fKeepD0fromBOnly flag is true
index 874ed53fa441cc90f58cf3ef8f8955a7a6985ab3..a29c1743caf4fa063f7472ac2452497ca83880e3 100644 (file)
@@ -80,7 +80,7 @@ AliCFTaskVertexingHF *AddTaskCFVertexingHF(const char* cutFile = "./D0toKpiCuts.
                return 0x0;
        }
 
-       TFile* fileCuts = new TFile(cutFile);
+       TFile* fileCuts = TFile::Open(cutFile);
        AliRDHFCutsD0toKpi *cutsD0toKpi = (AliRDHFCutsD0toKpi*)fileCuts->Get("D0toKpiCutsStandard");
        
        // check that the fKeepD0fromB flag is set to true when the fKeepD0fromBOnly flag is true
index 94cb2ba353d4beb392daf0b1cd6f8f436f7e9f3d..efa672bbdfcbd755bcd2785e0a3587acf8703714 100644 (file)
@@ -75,7 +75,7 @@ AliCFTaskVertexingHF *AddTaskCFVertexingHF3Prong(const char* cutFile = "./Dplust
                return 0x0;
        }
 
-       TFile* fileCuts = new TFile(cutFile);
+       TFile* fileCuts = TFile::Open(cutFile);
        AliRDHFCutsDplustoKpipi *cutsDplustoKpipi = (AliRDHFCutsDplustoKpipi*)fileCuts->Get("AnalysisCuts");
        
        // check that the fKeepD0fromB flag is set to true when the fKeepD0fromBOnly flag is true
index 53aa32f58e0338711f9f5bcfda29a6d8ce7de732..97cf4ae868cac749dc60e0074b7a9b5491f04f5c 100644 (file)
@@ -81,7 +81,7 @@ AliCFContainer *AddTaskCFVertexingHF3ProngLc(const char* cutFile = "./cuts4Lctop
                return 0x0;
        }
        
-       TFile* fileCuts = new TFile(cutFile);
+       TFile* fileCuts = TFile::Open(cutFile);
        AliRDHFCutsLctopKpi *cutsLctopKpi = (AliRDHFCutsLctopKpi*)fileCuts->Get("LctopKpiProdCuts");
        
        // check that the fKeepD0fromB flag is set to true when the fKeepD0fromBOnly flag is true
index a889aa55f4e8bce09279b38acf675c0827a66924..158c76d7629654fb7bae40f29ebcb4ca2796d28d 100644 (file)
@@ -49,7 +49,7 @@ AliCFTaskVertexingHF *AddTaskCFVertexingHFCascade(const char* cutFile = "./DStar
                return 0x0;
        }
 
-       TFile* fileCuts = new TFile(cutFile);
+       TFile* fileCuts = TFile::Open(cutFile);
        AliRDHFCutsDStartoKpipi *cutsD0toKpi = (AliRDHFCutsDStartoKpipi*)fileCuts->Get("DStartoKpipiCuts");
        
        // check that the fKeepD0fromB flag is set to true when the fKeepD0fromBOnly flag is true
index e985c22fc1d69ba5914ead51a4254248a4cede5c..750f5ad1b0b52eff6da81b36774aa42ddaaecc83 100644 (file)
@@ -125,7 +125,7 @@ AliAnalysisTaskSED0Mass *AddTaskD0Mass(Int_t flag=0/*0 = D0,1 = LS*/,Bool_t read
     //     printf("    cosThetaPoint    > %f\n",fD0toKpiCuts[8]);
 
   Bool_t stdcuts=kFALSE;
-  TFile* filecuts=new TFile(finname.Data());
+  TFile* filecuts=TFile::Open(finname.Data());
   if(!filecuts->IsOpen()){
     cout<<"Input file not found: using std cut object"<<endl;
     stdcuts=kTRUE;
index 057a629545aea7989b0310889d2c76d617728b51..3bd2a9dce38e1f9402c665b3450470a7da2a5345 100644 (file)
@@ -11,7 +11,7 @@ AliAnalysisTaskSEDStarJets *AddTaskDStarJets(Bool_t theMCon=kTRUE)
     return NULL;
   } 
 
-  TFile* filecuts=new TFile("DStartoKpipiCuts.root");
+  TFile* filecuts=TFile::Open("DStartoKpipiCuts.root");
   if(!filecuts->IsOpen()){
     cout<<"Input file not found: exit"<<endl;
     return;
index 591337bea9fee75cd3689dd41310833daf653750..d00b5eac9c3b74e9f9576675162470106ed6fb68 100644 (file)
@@ -42,7 +42,7 @@ AliAnalysisTaskSEDStarSpectra *AddTaskDStarSpectra(Int_t system=0/*0=pp,1=PbPb*/
 
   Bool_t stdcuts=kFALSE;
 
-  TFile* filecuts=new TFile("DStartoKpipiCuts.root");
+  TFile* filecuts=TFile::Open("DStartoKpipiCuts.root");
 
   if(!filecuts->IsOpen()){
 
index 8080361782fb96ef941bd117fb4d05b85ebf5a59..4971efbdedd0017493a568bf2a835e75eb80b8ab 100644 (file)
@@ -20,7 +20,7 @@ AliAnalysisTaskSEDplus *AddTaskDplus(Int_t system=0/*0=pp,1=PbPb*/,
   }
 
   Bool_t stdcuts=kFALSE;
-  TFile* filecuts=new TFile(filename.Data());
+  TFile* filecuts=TFile::Open(filename.Data());
   if(!filecuts->IsOpen()){
     cout<<"Input file not found: using standard cuts"<<endl;
     stdcuts=kTRUE;
index d382d0dae78b367e6056dc4097d5d27cb7d03c87..60988290ee90fdcbe8852ec4802c7a6ce0825c8e 100644 (file)
@@ -17,7 +17,7 @@ AliAnalysisTaskSEDs *AddTaskDs(Int_t storeNtuple=0,Bool_t readMC=kFALSE,
   }
 
 
-  TFile* filecuts=new TFile(filename.Data());
+  TFile* filecuts=TFile::Open(filename.Data());
   if(!filecuts->IsOpen()){
     cout<<"Error: Input file not found!"<<endl;
     return 0;
index 72c4c1a8e5bc39e624ff247366d3d22ff7ec2410..291e6329f8b709f963993d170daac0142116c1d3 100644 (file)
@@ -10,7 +10,7 @@ AliAnalysisTaskSEHFQA* AddTaskHFQA(AliAnalysisTaskSEHFQA::DecChannel ch,TString
   }\r
 \r
   Bool_t stdcuts=kFALSE;\r
-  TFile* filecuts=new TFile(filecutsname.Data());\r
+  TFile* filecuts=TFile::Open(filecutsname.Data());\r
   if(!filecuts->IsOpen()){\r
     cout<<"Input file not found: using std cut object"<<endl;\r
     stdcuts=kTRUE;\r
index c638cab8d6af48d032abb42cba29696c3c6939e3..1f9938277000f15b1ea78eb4a57aaf2a39aee9f0 100644 (file)
@@ -10,7 +10,7 @@ AliAnalysisTaskSELambdac *AddTaskLambdac(TString finname,Bool_t storeNtuple,Bool
 
 
   Bool_t stdcuts=kFALSE;
-  TFile* filecuts=new TFile(finname.Data());
+  TFile* filecuts=TFile::Open(finname.Data());
   if(!filecuts->IsOpen()){
    cout<<"Input file not found: using std cut object"<<endl;
    stdcuts=kTRUE;
index 0fc33e1a335e2be18fc51fba567fa6a1ec87965c..1c917f1d3445bbd67fe3ab01597c0fbecdfa1ff6 100644 (file)
@@ -22,7 +22,7 @@ AliAnalysisTaskSESelectHF4Prong *AddTaskSelectHF4Prong()
   mgr->SetOutputEventHandler(aodHandler);\r
  
   //Cuts loading
-  TFile* filecuts=new TFile("Charm4ProngCutsDef.root");
+    TFile* filecuts=TFile::Open("Charm4ProngCutsDef.root");
   if(!filecuts->IsOpen()){
     cout<<"Input file not found: exit"<<endl;
     return;
index f0ba8ebf07523d666de44194ad420d9add57b5f1..cb22be9d754c69a1c6043284a658bc803fefbf58 100644 (file)
@@ -14,7 +14,7 @@ AliAnalysisTaskSESignificance *AddTaskSignificance(TString filename="cuts4Signif
     return NULL;
   }
 
-  TFile* filecuts=new TFile(filename.Data());
+  TFile* filecuts=TFile::Open(filename.Data());
   if(!filecuts->IsOpen()){
     cout<<"Input file not found: exit"<<endl;
     return;