]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MFT/AliMFTHit.h
rulechecker
[u/mrichter/AliRoot.git] / MFT / AliMFTHit.h
CommitLineData
820b4d9e 1#ifndef AliMFTHit_H
2#define AliMFTHit_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7//====================================================================================================================================================
8//
9// Hit description for the ALICE Muon Forward Tracker
10//
11// Contact author: antonio.uras@cern.ch
12//
13//====================================================================================================================================================
14
15#include "TLorentzVector.h"
16#include "TParticle.h"
17#include "AliHit.h"
18#include "AliRun.h"
19#include "AliMC.h"
20
21//====================================================================================================================================================
22
23class TParticle;
24
25class AliMFTHit : public AliHit {
26
27public:
28
29 AliMFTHit();
30// AliMFTHit(const AliMFTHit &h);
31// AliMFTHit& operator=(const AliMFTHit &h);
32
33 virtual ~AliMFTHit() {}
34
35 virtual void SetPlane(Int_t plane) { fPlane = plane; }
36 virtual void SetDetElemID(Int_t detElemID) { fDetElemID = detElemID; }
37 virtual void SetPosition(TLorentzVector &x) { fX =x.X(); fY =x.Y(); fZ =x.Z(); }
38 virtual void SetTOF(Double_t time) { fTOF = time; }
39 virtual void SetStatus(Int_t status) { fStatus = status; }
40 virtual void SetEloss(Double_t energy) { fEloss = energy; }
41 virtual void SetMomentum(TLorentzVector &p) { fPx=p.Px(); fPy=p.Py(); fPz=p.Pz(); }
42
43 virtual Int_t GetTrackStatus() const { return fStatus; }
44 virtual Int_t GetPlane() const { return fPlane; }
45 virtual Int_t GetDetElemID() const { return fDetElemID; }
46 virtual Double_t GetEloss() const { return fEloss; }
47 virtual Double_t GetTOF() const { return fTOF; }
48
49 virtual void GetPosition(Double_t &x,Double_t &y,Double_t &z) const { x=fX; y=fY; z=fZ; }
50 virtual Double_t GetX() const { return fX; }
51 virtual Double_t GetY() const { return fY; }
52 virtual Double_t GetZ() const { return fZ; }
53
54 virtual void GetMomentum(Double_t &px,Double_t &py,Double_t &pz) const { px=fPx; py=fPy; pz=fPz; }
55 virtual Double_t GetPx() const { return fPx; }
56 virtual Double_t GetPy() const { return fPy; }
57 virtual Double_t GetPz() const { return fPz; }
58
59 TParticle* GetParticle() const;
60
61 Bool_t IsInside() const { return (fStatus == 1); }
62 Bool_t IsEntering() const { return (fStatus == 2); }
63 Bool_t IsExiting() const { return (fStatus == 4); }
64 Bool_t IsOut() const { return (fStatus == 8); }
65 Bool_t IsDisappeared() const { return (fStatus == 16); }
66 Bool_t IsStopped() const { return (fStatus == 32); }
67 Bool_t IsAlive() const { return (fStatus == 64); }
68
69protected:
70
71 Int_t fStatus; /* The track status flag. This flag indicates the track status
72 at the time of creating this hit.
73 It is made up of the following 8 status bits from highest order to lowest order bits 0 :
74 IsTrackAlive(): IsTrackStop(): IsTrackDisappeared(): IsTrackOut(): IsTrackExiting(): IsTrackEntering(): IsTrackInside() .
75 See AliMC for a description of these functions.
76 If the function is true then the bit is set to one, otherwise it is zero. */
77
78 Int_t fPlane; // Plane number
79 Int_t fDetElemID; // Detection Element unique ID
80 Double_t fPx; // PX of particle at the point of the hit
81 Double_t fPy; // PY of particle at the point of the hit
82 Double_t fPz; // PZ of particle at the point of the hit
83 Double_t fEloss; // Energy deposited in the current step
84 Double_t fTOF; // Time of flight at the point of the hit
85
86 ClassDef(AliMFTHit,3)
87
88};
89
90//====================================================================================================================================================
91
92#endif