]> git.uio.no Git - u/mrichter/AliRoot.git/blame - ANALYSIS/macros/AddTaskFilterFriendSecond.C
Enable the TPC HV dip check for 2013 data and the incomplete events rejection for...
[u/mrichter/AliRoot.git] / ANALYSIS / macros / AddTaskFilterFriendSecond.C
CommitLineData
a9253433 1//=============================================================================
2//
3// *** AddTaskFilterFriendSecond.C ***
4//
5// This macro initialize a complete AnalysisTask object for filtering ESD with AliAnalysisTaskFilterFriendSecond.
6//
7//=============================================================================
8
9AliAnalysisTaskFilterFriendSecond *AddTaskFilterFriendSecond()
10{
11
12 // pointer to the analysis manager
13 AliAnalysisManager *mgr = AliAnalysisManager::GetAnalysisManager();
14 if (!mgr) {
15 Error("AddTaskTOFCalib", "No analysis manager to connect to.");
16 return NULL;
17 }
18
19 // check the input handler
20 if (!mgr->GetInputEventHandler()) {
21 ::Error("AddTask", "This task requires an input event handler");
22 return NULL;
23 }
24 TString type = mgr->GetInputEventHandler()->GetDataType(); // can be "ESD" or "AOD"
25
26 // create the task
27 AliAnalysisTaskFilterFriendSecond* filter = new AliAnalysisTaskFilterFriendSecond("filter_2");
28 mgr->AddTask(filter);
29
30 // connecting the input/output containers
31 AliAnalysisDataContainer *cinput0 = mgr->GetCommonInputContainer();
32 AliAnalysisDataContainer *coutput0 = mgr->GetCommonOutputContainer();
33
34 mgr->ConnectInput (filter, 0, cinput0 );
35 //mgr->ConnectOutput(filter, 0, coutput0);
36
37 return filter;
38}