]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MUON/AliMUONData.h
Correction of extrusions and overlaps.
[u/mrichter/AliRoot.git] / MUON / AliMUONData.h
CommitLineData
6309cf6e 1#ifndef ALIMUONDATA_H
2#define ALIMUONDATA_H
3//
1391e633 4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
50837721 5 * See cxx source for full Copyright notice */
6
7/* $Id$ */
8
6309cf6e 9// AliMUONData
10// Class containing MUON data: hits, digits, rawclusters, globaltrigger, localtrigger, etc ...
11// Gines Martinez, Subatech, September 2003
12//
13
1a1cdff8 14#include "AliLoader.h"
6309cf6e 15
16class TClonesArray;
1a1cdff8 17class TNamed;
6309cf6e 18class TObjArray;
19class TTree;
20
1a1cdff8 21
22class AliMUONConstants;
6309cf6e 23class AliMUONRawCluster;
dcd2690d 24class AliMUONTrack;
6309cf6e 25
26//__________________________________________________________________
27/////////////////////////////////////////////////////////////////////
28// //
29// class AliMUONData //
30// //
31/////////////////////////////////////////////////////////////////////
32
33class AliMUONData : public TNamed {
34 public:
35 AliMUONData();
36 AliMUONData(AliLoader * loader, const char* name, const char* title);
37 AliMUONData(const AliMUONData& rMUONData);
38 virtual ~AliMUONData();
39 virtual void AddDigit(Int_t id, Int_t* tracks, Int_t* charges,
40 Int_t* digits);
41 virtual void AddHit(Int_t fIshunt, Int_t track, Int_t iChamber,
42 Int_t idpart, Float_t X, Float_t Y, Float_t Z,
43 Float_t tof, Float_t momentum, Float_t theta,
44 Float_t phi, Float_t length, Float_t destep);
1391e633 45 virtual void AddHit(Int_t fIshunt, Int_t track, Int_t iChamber,
46 Int_t idpart, Float_t X, Float_t Y, Float_t Z,
47 Float_t tof, Float_t momentum, Float_t theta,
48 Float_t phi, Float_t length, Float_t destep,
49 Float_t Xref,Float_t Yref,Float_t Zref);
6309cf6e 50 virtual void AddGlobalTrigger(Int_t *singlePlus, Int_t *singleMinus,
51 Int_t *singleUndef, Int_t *pairUnlike,
52 Int_t *pairLike);
53 virtual void AddLocalTrigger(Int_t* ltrigger);
54 virtual void AddRawCluster(Int_t id, const AliMUONRawCluster& clust);
dcd2690d 55 virtual void AddRecTrack(const AliMUONTrack& track);
56
6309cf6e 57 TClonesArray* Hits() {return fHits;}
1a1cdff8 58 TClonesArray* Digits(Int_t DetectionPlane)
6309cf6e 59 {return ( (TClonesArray*) fDigits->At(DetectionPlane) );}
60 TClonesArray* LocalTrigger() {return fLocalTrigger;}
61 TClonesArray* GlobalTrigger() {return fGlobalTrigger;}
62 TClonesArray* RawClusters(Int_t DetectionPlane)
63 {return ( (TClonesArray*) fRawClusters->At(DetectionPlane) );}
dcd2690d 64 TClonesArray* RecTracks() {return fRecTracks;}
1a1cdff8 65
66 void GetTrack(Int_t it) {fLoader->TreeH()->GetEvent(it);}
3a87c34c 67 Int_t GetNtracks() {return (Int_t) fLoader->TreeH()->GetEntries();}
1a1cdff8 68 void GetCathode(Int_t ic) {fLoader->TreeD()->GetEvent(ic);}
69 void GetRawClusters() {fLoader->TreeR()->GetEvent(0);}
70 void GetTrigger() {fLoader->TreeR()->GetEvent(0);}
d652f85c 71 Int_t GetSplitLevel() {return fSplitLevel;}
1a1cdff8 72
c1d45bdf 73 Bool_t IsRawClusterBranchesInTree();
74 Bool_t IsTriggerBranchesInTree();
75
ce3f5e87 76 virtual AliLoader* GetLoader() {return fLoader;}
77 virtual void SetLoader(AliLoader * loader) {fLoader=loader;}
dcd2690d 78
1a1cdff8 79 virtual void Fill(Option_t* opt=" ");
6309cf6e 80 virtual void MakeBranch(Option_t *opt=" ");
ce3f5e87 81 virtual void SetTreeAddress(Option_t *opt=" ");
dcd2690d 82
d652f85c 83 void SetSplitLevel(Int_t SplitLevel) {fSplitLevel=SplitLevel;}
84
85
6309cf6e 86 virtual void ResetHits();
87 virtual void ResetDigits();
88 virtual void ResetTrigger();
89 virtual void ResetRawClusters();
dcd2690d 90 virtual void ResetRecTracks();
6309cf6e 91
92 TTree* TreeH() {return fLoader->TreeH(); }
93 TTree* TreeD() {return fLoader->TreeD(); }
94 TTree* TreeR() {return fLoader->TreeR(); }
95 TTree* TreeT() {return fLoader->TreeT(); }
96 TTree* TreeP() {return fLoader->TreeP(); }
97
98 private:
99 //descendant classes should
100 //use protected interface methods to access these folders
101
102
103 protected:
104 AliLoader* fLoader;
105
dcd2690d 106 // One event in treeH per primary track
107 TClonesArray* fHits;
108 // One event in treeD and one branch per detection plane
109 TObjArray* fDigits;
110 //One event in TreeR/Rawcluster and one branch per tracking detection plane
111 TObjArray* fRawClusters;
112 //! List of Global Trigger One event in TreeR/GlobalTriggerBranch
113 TClonesArray* fGlobalTrigger;
114 //! List of Local Trigger, One event in TreeR/LocalTriggerBranch
115 TClonesArray* fLocalTrigger;
116 // pointer to array of reconstructed tracks
117 TClonesArray* fRecTracks;
118
c1d45bdf 119 Int_t fNhits; //!
120 Int_t* fNdigits;//!
121 Int_t* fNrawclusters;//!
122 Int_t fNglobaltrigger;//!
123 Int_t fNlocaltrigger;//!
124 Int_t fNrectracks; //!
d652f85c 125 Int_t fSplitLevel; // Splitting of branches 0 no spitting (root files are smaller) 1 splitting (larger output files)
6309cf6e 126
127 ClassDef(AliMUONData,1)
128 };
129#endif