Tracks reconstruction using NewIO
[u/mrichter/AliRoot.git] / MUON / AliMUONData.h
CommitLineData
6309cf6e 1#ifndef ALIMUONDATA_H
2#define ALIMUONDATA_H
3//
4// AliMUONData
5// Class containing MUON data: hits, digits, rawclusters, globaltrigger, localtrigger, etc ...
6// Gines Martinez, Subatech, September 2003
7//
8
9#include "TNamed.h"
10
11#include "AliLoader.h"
12#include "AliMUONConstants.h"
13
14class TClonesArray;
15class TObjArray;
16class TTree;
17
18class AliMUONRawCluster;
dcd2690d 19class AliMUONTrack;
6309cf6e 20
21//__________________________________________________________________
22/////////////////////////////////////////////////////////////////////
23// //
24// class AliMUONData //
25// //
26/////////////////////////////////////////////////////////////////////
27
28class AliMUONData : public TNamed {
29 public:
30 AliMUONData();
31 AliMUONData(AliLoader * loader, const char* name, const char* title);
32 AliMUONData(const AliMUONData& rMUONData);
33 virtual ~AliMUONData();
34 virtual void AddDigit(Int_t id, Int_t* tracks, Int_t* charges,
35 Int_t* digits);
36 virtual void AddHit(Int_t fIshunt, Int_t track, Int_t iChamber,
37 Int_t idpart, Float_t X, Float_t Y, Float_t Z,
38 Float_t tof, Float_t momentum, Float_t theta,
39 Float_t phi, Float_t length, Float_t destep);
40 virtual void AddGlobalTrigger(Int_t *singlePlus, Int_t *singleMinus,
41 Int_t *singleUndef, Int_t *pairUnlike,
42 Int_t *pairLike);
43 virtual void AddLocalTrigger(Int_t* ltrigger);
44 virtual void AddRawCluster(Int_t id, const AliMUONRawCluster& clust);
dcd2690d 45 virtual void AddRecTrack(const AliMUONTrack& track);
46
6309cf6e 47 TClonesArray* Hits() {return fHits;}
48 TClonesArray* Digits(Int_t DetectionPlane, Int_t /*Cathode*/)
49 {return ( (TClonesArray*) fDigits->At(DetectionPlane) );}
50 TClonesArray* LocalTrigger() {return fLocalTrigger;}
51 TClonesArray* GlobalTrigger() {return fGlobalTrigger;}
52 TClonesArray* RawClusters(Int_t DetectionPlane)
53 {return ( (TClonesArray*) fRawClusters->At(DetectionPlane) );}
dcd2690d 54 TClonesArray* RecTracks() {return fRecTracks;}
55
ce3f5e87 56 virtual AliLoader* GetLoader() {return fLoader;}
57 virtual void SetLoader(AliLoader * loader) {fLoader=loader;}
dcd2690d 58
6309cf6e 59 virtual void MakeBranch(Option_t *opt=" ");
ce3f5e87 60 virtual void SetTreeAddress(Option_t *opt=" ");
dcd2690d 61
6309cf6e 62 virtual void ResetHits();
63 virtual void ResetDigits();
64 virtual void ResetTrigger();
65 virtual void ResetRawClusters();
dcd2690d 66 virtual void ResetRecTracks();
6309cf6e 67
68 TTree* TreeH() {return fLoader->TreeH(); }
69 TTree* TreeD() {return fLoader->TreeD(); }
70 TTree* TreeR() {return fLoader->TreeR(); }
71 TTree* TreeT() {return fLoader->TreeT(); }
72 TTree* TreeP() {return fLoader->TreeP(); }
73
74 private:
75 //descendant classes should
76 //use protected interface methods to access these folders
77
78
79 protected:
80 AliLoader* fLoader;
81
dcd2690d 82 // One event in treeH per primary track
83 TClonesArray* fHits;
84 // One event in treeD and one branch per detection plane
85 TObjArray* fDigits;
86 //One event in TreeR/Rawcluster and one branch per tracking detection plane
87 TObjArray* fRawClusters;
88 //! List of Global Trigger One event in TreeR/GlobalTriggerBranch
89 TClonesArray* fGlobalTrigger;
90 //! List of Local Trigger, One event in TreeR/LocalTriggerBranch
91 TClonesArray* fLocalTrigger;
92 // pointer to array of reconstructed tracks
93 TClonesArray* fRecTracks;
94
6309cf6e 95 Int_t fNhits;
96 Int_t* fNdigits;
97 Int_t* fNrawclusters;
98 Int_t fNglobaltrigger;
99 Int_t fNlocaltrigger;
dcd2690d 100 Int_t fNrectracks;
6309cf6e 101
102 ClassDef(AliMUONData,1)
103 };
104#endif