ROOT logo
#ifndef AliMFTHit_H
#define AliMFTHit_H

/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
 * See cxx source for full Copyright notice                               */

//====================================================================================================================================================
//
//      Hit description for the ALICE Muon Forward Tracker
//
//      Contact author: antonio.uras@cern.ch
//
//====================================================================================================================================================

#include "TLorentzVector.h"
#include "TParticle.h"
#include "AliHit.h"
#include "AliRun.h"
#include "AliMC.h"

//====================================================================================================================================================

class TParticle;

class AliMFTHit : public AliHit {

public:

  AliMFTHit();
//   AliMFTHit(const AliMFTHit &h);
//   AliMFTHit& operator=(const AliMFTHit &h);
  
  virtual ~AliMFTHit() {}
  
  virtual void SetPlane(Int_t plane) { fPlane = plane; }
  virtual void SetDetElemID(Int_t detElemID) { fDetElemID = detElemID; }
  virtual void SetPosition(TLorentzVector &x) { fX =x.X(); fY =x.Y(); fZ =x.Z(); }
  virtual void SetTOF(Double_t time) { fTOF = time; }
  virtual void SetStatus(Int_t status) { fStatus  = status; }
  virtual void SetEloss(Double_t energy) { fEloss = energy; }
  virtual void SetMomentum(TLorentzVector &p) { fPx=p.Px(); fPy=p.Py(); fPz=p.Pz(); }
  
  virtual Int_t GetTrackStatus() const { return fStatus;  }
  virtual Int_t GetPlane()       const { return fPlane; }
  virtual Int_t GetDetElemID()   const { return fDetElemID; }
  virtual Double_t GetEloss()    const { return fEloss; }
  virtual Double_t GetTOF()      const { return fTOF; }
  
  virtual void GetPosition(Double_t &x,Double_t &y,Double_t &z) const { x=fX; y=fY; z=fZ; }
  virtual Double_t GetX() const { return fX; }
  virtual Double_t GetY() const { return fY; }
  virtual Double_t GetZ() const { return fZ; }

  virtual void GetMomentum(Double_t &px,Double_t &py,Double_t &pz) const { px=fPx; py=fPy; pz=fPz; }
  virtual Double_t GetPx() const { return fPx; }
  virtual Double_t GetPy() const { return fPy; }
  virtual Double_t GetPz() const { return fPz; }

  TParticle* GetParticle() const;

  Bool_t IsInside()      const { return (fStatus & 0x1);    } 
  Bool_t IsEntering()    const { return (fStatus & 0x1<<1); }
  Bool_t IsExiting()     const { return (fStatus & 0x1<<2); }
  Bool_t IsOut()         const { return (fStatus & 0x1<<3); }
  Bool_t IsDisappeared() const { return (fStatus & 0x1<<4); }
  Bool_t IsStopped()     const { return (fStatus & 0x1<<5); }
  Bool_t IsAlive()       const { return (fStatus & 0x1<<6); }

protected:

  Int_t   fStatus;   /* The track status flag. This flag indicates the track status
			at the time of creating this hit. 
			It is made up of the following 8 status bits from highest order to lowest order bits 0 :  
			IsTrackAlive(): IsTrackStop(): IsTrackDisappeared(): IsTrackOut(): IsTrackExiting(): IsTrackEntering(): IsTrackInside()     .
			See AliMC for a description of these functions. 
			If the function is true then the bit is set to one, otherwise it is zero. */
  
  Int_t    fPlane;      // Plane number
  Int_t    fDetElemID;  // Detection Element unique ID 
  Double_t fPx;         // PX of particle at the point of the hit
  Double_t fPy;         // PY of particle at the point of the hit
  Double_t fPz;         // PZ of particle at the point of the hit
  Double_t fEloss;      // Energy deposited in the current step
  Double_t fTOF;        // Time of flight at the point of the hit
  
  ClassDef(AliMFTHit,3)
    
};

//====================================================================================================================================================

#endif
 AliMFTHit.h:1
 AliMFTHit.h:2
 AliMFTHit.h:3
 AliMFTHit.h:4
 AliMFTHit.h:5
 AliMFTHit.h:6
 AliMFTHit.h:7
 AliMFTHit.h:8
 AliMFTHit.h:9
 AliMFTHit.h:10
 AliMFTHit.h:11
 AliMFTHit.h:12
 AliMFTHit.h:13
 AliMFTHit.h:14
 AliMFTHit.h:15
 AliMFTHit.h:16
 AliMFTHit.h:17
 AliMFTHit.h:18
 AliMFTHit.h:19
 AliMFTHit.h:20
 AliMFTHit.h:21
 AliMFTHit.h:22
 AliMFTHit.h:23
 AliMFTHit.h:24
 AliMFTHit.h:25
 AliMFTHit.h:26
 AliMFTHit.h:27
 AliMFTHit.h:28
 AliMFTHit.h:29
 AliMFTHit.h:30
 AliMFTHit.h:31
 AliMFTHit.h:32
 AliMFTHit.h:33
 AliMFTHit.h:34
 AliMFTHit.h:35
 AliMFTHit.h:36
 AliMFTHit.h:37
 AliMFTHit.h:38
 AliMFTHit.h:39
 AliMFTHit.h:40
 AliMFTHit.h:41
 AliMFTHit.h:42
 AliMFTHit.h:43
 AliMFTHit.h:44
 AliMFTHit.h:45
 AliMFTHit.h:46
 AliMFTHit.h:47
 AliMFTHit.h:48
 AliMFTHit.h:49
 AliMFTHit.h:50
 AliMFTHit.h:51
 AliMFTHit.h:52
 AliMFTHit.h:53
 AliMFTHit.h:54
 AliMFTHit.h:55
 AliMFTHit.h:56
 AliMFTHit.h:57
 AliMFTHit.h:58
 AliMFTHit.h:59
 AliMFTHit.h:60
 AliMFTHit.h:61
 AliMFTHit.h:62
 AliMFTHit.h:63
 AliMFTHit.h:64
 AliMFTHit.h:65
 AliMFTHit.h:66
 AliMFTHit.h:67
 AliMFTHit.h:68
 AliMFTHit.h:69
 AliMFTHit.h:70
 AliMFTHit.h:71
 AliMFTHit.h:72
 AliMFTHit.h:73
 AliMFTHit.h:74
 AliMFTHit.h:75
 AliMFTHit.h:76
 AliMFTHit.h:77
 AliMFTHit.h:78
 AliMFTHit.h:79
 AliMFTHit.h:80
 AliMFTHit.h:81
 AliMFTHit.h:82
 AliMFTHit.h:83
 AliMFTHit.h:84
 AliMFTHit.h:85
 AliMFTHit.h:86
 AliMFTHit.h:87
 AliMFTHit.h:88
 AliMFTHit.h:89
 AliMFTHit.h:90
 AliMFTHit.h:91
 AliMFTHit.h:92