]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWG/DevNanoAOD/AliNanoAODReplicator.h
correcting number of supermodules for DCal
[u/mrichter/AliRoot.git] / PWG / DevNanoAOD / AliNanoAODReplicator.h
CommitLineData
778636d4 1#ifndef ALINANOAODREPLICATO_H
2#define ALINANOAODREPLICATO_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5* See cxx source for full Copyright notice */
6
7// $Id: AliAODMuonReplicator.h 56492 2012-05-15 18:42:47Z pcrochet $
8
9
10#ifndef ALIDAODBRANCHREPLICATOR_H
11# include "AliAODBranchReplicator.h"
12#endif
13#ifndef ROOT_TExMap
14# include "TExMap.h"
15#endif
16
17#include <iostream>
18
19/* #ifndef AliAOD3LH_H */
20/* #include "AliAOD3LH.h" */
21/* #endif */
22
23//#include "AliAOD3LH.h"
24
25//
26// Implementation of a branch replicator
27// to produce nano AOD.
28//
29// Author: Michele Floris, michele.floris@cern.ch
30
31class AliAnalysisCuts;
32class TClonesArray;
33class AliAODMCHeader;
34class AliAODVZERO;
35class AliAODTZERO;
36class AliPIDResponse;
37class AliESDv0;
38class TArrayI;
39class AliAODv0;
40class TRefArray;
41class AliAODRecoDecay;
42class AliAODRecoDecayHF;
43class AliAODRecoDecayHF2Prong;
44class AliVertexerTracks;
45
46class AliESDVertex;
47class AliESDtrack;
48class AliVEvent;
49class AliAODVertex;
50class AliVertexerTracks;
51class AliESDv0;
52class AliAODv0;
53class AliAODHeader;
54class AliNanoAODHeader;
55class AliAnalysisTaskSE;
56class AliNanoAODTrack;
57class AliAODTrack;
58class AliNanoAODCustomSetter;
59
60class TH1F;
61
62class AliNanoAODReplicator : public AliAODBranchReplicator
63{
64 public:
65
66 AliNanoAODReplicator(const char* name="AliNanoAODReplicator",
67 const char* title="Branch Replicator for special tracks related branches",
68 const char * varlist="pt,eta",
69 AliAnalysisCuts* trackCut=0x0,
70 Int_t mcMode=0
71 );
72
73 virtual ~AliNanoAODReplicator();
74
75 virtual TList* GetList() const ; // FIXME: This is declared const in the interface
76
77 virtual void ReplicateAndFilter(const AliAODEvent& source);
78
79 virtual void Terminate();
80
81 const char * GetVarList() { return fVarList; }
82 void SetVarList (const char * var) { fVarList = var;}
83 const char * GetVarListHeader() { return fVarListHeader; }
84 void SetVarListHeader (const char * var) { fVarListHeader = var;}
85
86 // Call backs for custom variables
87 AliNanoAODCustomSetter * GetCustomSetter() { return fCustomSetter; }
88 void SetCustomSetter (AliNanoAODCustomSetter * var) { fCustomSetter = var; }
89
90
91 private:
92
93 void SelectParticle(Int_t i);
94 Bool_t IsParticleSelected(Int_t i);
95 void CreateLabelMap(const AliAODEvent& source);
96 Int_t GetNewLabel(Int_t i);
97 void FilterMC(const AliAODEvent& source);
98
99
778636d4 100 private:
101
102 AliAnalysisCuts* fTrackCut; // decides which tracks to keep
103 mutable TClonesArray* fTracks; //! internal array of arrays of NanoAOD tracks
104 mutable AliNanoAODHeader* fHeader; //! internal array of headers
105 Int_t fNTracksVariables; //! Number of variables in the array
106
107 mutable TClonesArray* fVertices; //! internal array of vertices
108
109 mutable TList* fList; //! internal list of managed objects (fVertices and fTracks)
110
111 mutable TClonesArray* fMCParticles; //! internal array of MC particles
112 mutable AliAODMCHeader* fMCHeader; //! internal array of MC header
113 Int_t fMCMode; // MC filtering switch (0=none=no mc information,1=normal=simple copy,>=2=aggressive=filter out : keep only particles leading to tracks and trheir relatives + all charged primaries)
114
115 TExMap fLabelMap; //! for MC label remapping (in case of aggressive filtering)
116 TExMap fParticleSelected; //! List of selected MC particles
117
5942de8c 118 TString fVarList; // list of variables to be filterered
119 TString fVarListHeader; // list of variables to be filtered (header)
778636d4 120
121 AliNanoAODCustomSetter * fCustomSetter; // Setter class for custom variables
122
123 private:
124
125
126 AliNanoAODReplicator(const AliNanoAODReplicator&);
127 AliNanoAODReplicator& operator=(const AliNanoAODReplicator&);
128
129 ClassDef(AliNanoAODReplicator,1) // Branch replicator for ESD to muon AOD.
130};
131
132#endif