]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TPC/AliTPCTrackHitsV2.h
Separated TOF libraries (base,rec,sim)
[u/mrichter/AliRoot.git] / TPC / AliTPCTrackHitsV2.h
CommitLineData
f641f6bd 1#ifndef ALITPCTRACKHITSV2_H
2#define ALITPCTRACKHITSV2_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6/* $Id$ */
7////////////////////////////////////////////////
8// Manager class for TPC hits //
9////////////////////////////////////////////////
018a927a 10//
f641f6bd 11
12#include "TObject.h"
13
14class TClonesArray;
15class AliArrayS;
16class AliTPChit;
17class AliTPCTempHitInfoV2;
18class AliTPCCurrentHitV2;
fce0283f 19class AliHit;
f641f6bd 20
21class AliTrackHitsParamV2 : public TObject {
9b1855ba 22 friend class AliTPC;
23 friend class AliTRD;
24 friend class AliTPCTrackHitsV2;
25 friend class AliTPCTempHitInfoV2;
26 friend class AliTRDtrackHits;
27
f641f6bd 28public:
29 AliTrackHitsParamV2();
53110b9d 30 AliTrackHitsParamV2(const AliTrackHitsParamV2 &hit): TObject(hit)
31 {hit.Copy(*this);}
32 AliTrackHitsParamV2& operator = (const AliTrackHitsParamV2 &hit)
33 {hit.Copy(*this); return (*this);}
f641f6bd 34 ~AliTrackHitsParamV2();
53110b9d 35
9b1855ba 36 private:
f641f6bd 37 Int_t fTrackID; // ID of the track
38 Short_t fVolumeID;// volume ID
39 Float_t fR; //radius
40 Float_t fZ; //z position
41 Float_t fFi; //radial angle
42 Float_t fAn; //angle with the radial vector
43 Float_t fAd; //derivation of angle
44 Float_t fTheta; //theta angle
45 Float_t fThetaD; //theta angle derivation
46 Int_t fNHits; //nuber of thits
47 Short_t * fHitDistance; //[fNHits] array of hits distances
48 Short_t * fCharge; //[fNHits] array of charges
53110b9d 49 static Int_t fgCounter1; //First internal counter
50 static Int_t fgCounter2; // Second internal counter
51
52 void Copy(TObject &) const
53 {Error("Copy","Not Implemented");}
54
f641f6bd 55 ClassDef(AliTrackHitsParamV2,1)
56};
57
58
f641f6bd 59class AliTPCTrackHitsV2 : public TObject {
9b1855ba 60 friend class AliTPCTempHitInfoV2;
53110b9d 61
f641f6bd 62public:
63 AliTPCTrackHitsV2();
64 ~AliTPCTrackHitsV2();
53110b9d 65 AliTPCTrackHitsV2(const AliTPCTrackHitsV2 &hit): TObject(hit)
66 {hit.Copy(*this);}
67 AliTPCTrackHitsV2& operator = (const AliTPCTrackHitsV2 &hit)
68 {hit.Copy(*this); return (*this);}
f641f6bd 69 void Clear();
70 void AddHitKartez(Int_t volumeID, Int_t trackID, Double_t x,
71 Double_t y, Double_t z,Int_t q);
72 void AddHit(Int_t volumeID, Int_t trackID, Double_t r,
73 Double_t z, Double_t fi,Int_t q);
74
75 Bool_t First(); //set current hit to first hit
76 Bool_t Next(); //set current hit to next
53110b9d 77 AliHit * GetHit() const;
f641f6bd 78 AliTrackHitsParamV2 * GetParam();
79
80 TClonesArray * GetArray(){return fArray;}
53110b9d 81 Int_t GetEntriesFast() const { return fSize;}
f641f6bd 82 void SetHitPrecision(Double_t prec) {fPrecision=prec;}
83 void SetStepPrecision(Double_t prec) {fStep=prec;}
84 void SetMaxDistance(UInt_t distance) {fMaxDistance = distance;}
85 Bool_t FlushHitStack(Bool_t force=kTRUE); //
86 Int_t * GetVolumes(){ return fVolumes;}
53110b9d 87 Int_t GetNVolumes() const {return fNVolumes;}
88
f641f6bd 89public:
90 void AddVolume(Int_t volume); //add volumes to tthe list of volumes
91 void FlushHitStack2(Int_t index1, Int_t index2); //
53110b9d 92
93protected:
f641f6bd 94 TClonesArray * fArray; //array of compressed hits
95 Int_t fSize; //total number of hits in track
96 Double_t fPrecision; // required precision
97 Double_t fStep; //unit step size
98 UInt_t fMaxDistance; //maximal distance between two connected hits
99 Int_t fNVolumes; //number of volumes in track
100 Int_t * fVolumes; //[fNVolumes] list of volumes
101 AliTPCTempHitInfoV2 * fTempInfo; //!information about track
102 AliTPCCurrentHitV2 * fCurrentHit; //!information about current hit
fce0283f 103 AliHit * fHit; //! current hit information
f641f6bd 104 static const Double_t fgkPrecision; //precision
105 static const Double_t fgkPrecision2; //precision
53110b9d 106 static Int_t fgCounter1; // First internal counter
107 static Int_t fgCounter2; // Second internal counter
108
109private:
110 void Copy(TObject &) const
111 {Error("Copy","Not Implemented");}
112
113
f641f6bd 114 ClassDef(AliTPCTrackHitsV2,1)
115};
116
fce0283f 117struct AliTPCCurrentHitV2 {
45bcf167 118 Int_t fParamIndex;// - current param pointer
119 Int_t fStackIndex; // - current hit stack index
fce0283f 120 Double_t fR; //current Radius
121 Bool_t fStatus; //current status
122};
123
124
f641f6bd 125
126#endif //ALITPCTRACKHITSV2_H