Move trigger container name to the add macro level
authormfasel <mfasel@lbl.gov>
Wed, 17 Sep 2014 07:52:09 +0000 (09:52 +0200)
committermverweij <marta.verweij@cern.ch>
Wed, 17 Sep 2014 09:08:22 +0000 (11:08 +0200)
PWGJE/EMCALJetTasks/UserTasks/AliAnalysisTaskPtEMCalTrigger.cxx
PWGJE/EMCALJetTasks/macros/AddTaskPtEMCalTrigger.C

index 375a9f2..f639319 100644 (file)
@@ -119,7 +119,6 @@ namespace EMCalTriggerPtAnalysis {
                AliParticleContainer *trackContainer = this->AddParticleContainer(trackContainerName.Data());
                trackContainer->SetClassName("AliVTrack");
                this->AddClusterContainer(clusterContainerName.Data());
-               this->SetCaloTriggerPatchInfoName("EmcalTriggers");
                fHistos = new AliEMCalHistoContainer("PtEMCalTriggerHistograms");
                fHistos->ReleaseOwner();
 
index 7990134..69815ce 100644 (file)
@@ -6,7 +6,7 @@
 #include <TString.h>
 #endif
 
-AliAnalysisTask* AddTaskPtEMCalTrigger(bool isMC, const char *period ="LHC13d"){
+AliAnalysisTask* AddTaskPtEMCalTrigger(bool usePythiaHard, const char *period ="LHC13d", const char *triggerContainer = ""){
                //AliLog::SetClassDebugLevel("EMCalTriggerPtAnalysis::AliAnalysisTaskPtEMCalTrigger", 2);
         AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();
          
@@ -26,10 +26,10 @@ AliAnalysisTask* AddTaskPtEMCalTrigger(bool isMC, const char *period ="LHC13d"){
         if(!TString(period).CompareTo("LHC13f")) pttriggertask->SetSwapEta();
         mgr->AddTask(pttriggertask);
         pttriggertask->SetPtRange(2., 100.);
-        if(isMC){
+        if(usePythiaHard){
                pttriggertask->SetIsPythia(kTRUE);
         }
-        std::cout << EMCalTriggerPtAnalysis::AliAnalysisTaskPtEMCalTrigger::Class_Name() << std::endl;
+        pttriggertask->SetCaloTriggerPatchInfoName(triggerContainer);
 
         // Create charged hadrons pPb standard track cuts
         AliESDtrackCuts *standardTrackCuts = AliESDtrackCuts::GetStandardITSTPCTrackCuts2011(true, 1);