area of Mathieson parametrized; hit ctor change eloss to qdc; Helix removed
[u/mrichter/AliRoot.git] / HMPID / AliHMPID.h
CommitLineData
d3da6dc4 1#ifndef AliHMPID_h
2#define AliHMPID_h
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6#include <AliDetector.h> //base class
7#include <TClonesArray.h> //XxxCreate()
3c6274c1 8#include <TObjArray.h> //fDig,fClu field
d3da6dc4 9
10
11
12class AliHMPID : public AliDetector //TObject-TNamed-AliModule-AliDetector-AliHMPID
13{
14public:
15//ctor & dtor
16 AliHMPID(const char *nm,const char *ttl); //named ctor
17 AliHMPID( ):AliDetector( ),fSdi(0),fDig(0),fClu(0) {} //default ctor
18 virtual ~AliHMPID();
19//framework part
20 void BuildGeometry ( ) {} //from AliModule invoked from AliMC::InitGeometry() to build geometry for old event display
21 virtual void CreateMaterials ( )=0; //from AliModule invoked from AliMC::ConstructGeometry() to define detector materials
22 virtual void CreateGeometry ( )=0; //from AliModule invoked from AliMC::ConstructGeometry() to build detector for simulation
d1bf51e1 23
d3da6dc4 24 virtual Int_t IsVersion ( )const=0; //from AliModule not used
25 virtual void Init ( )=0; //from AliModule invoked from AliMC::InitGeometry() after CreateGeometry() to do VolID initialization
661663fa 26 virtual void DefineOpticalProperties() {} //from AliModule invoked from AliMC::ConstructOpGeometry() to set Cerenkov properties
d3da6dc4 27 void MakeBranch (Option_t *opt=""); //from AliModule invokde from AliRun::Tree2Tree() to make requested HMPID branch
28 void SetTreeAddress ( ); //from AliModule invoked from AliRun::GetEvent(), AliLoader::SetTAddrInDet()
29 virtual void StepManager ( )=0; //from AliModule invoked from AliMC
30//private part +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1d4857c5 31 void HitCreate( ) {if(fHits)return; fHits=new TClonesArray("AliHMPIDHit"); fNhits=0; }//create hits list
d3da6dc4 32
33 TClonesArray* SdiLst ( )const{return fSdi; }//get sdigits list
1d4857c5 34 void SdiCreate( ) {if(fSdi)return; fSdi=new TClonesArray("AliHMPIDDigit"); }//create sdigits list
d3da6dc4 35 void SdiReset ( ) {if(fSdi) fSdi ->Clear(); }//clean sdigits list
d3da6dc4 36
37 TObjArray* DigLst ( )const{return fDig; }//get digits list for all chambers
38 TClonesArray* DigLst (Int_t c )const{return fDig ? (TClonesArray *)fDig->At(c):0; }//get digits list for chamber
470d5932 39 void DigCreate( ) {
40 if (fDig) return; //PH do not recreate existing containers
41 fDig=new TObjArray(7);for(Int_t i=0;i<7;i++)fDig->AddAt(new TClonesArray("AliHMPIDDigit"),i); }//create digits list
d3da6dc4 42 void DigReset ( ) {if(fDig)for(int i=0;i<7;i++)fDig->At(i)->Clear(); }//clean digits list
d3da6dc4 43
3c6274c1 44 TObjArray* CluLst ( )const{return fClu; }//get clusters list for all chambers
d3da6dc4 45 TClonesArray* CluLst (Int_t c )const{return fClu ? (TClonesArray *)fClu->At(c):0; }//get clusters list for chamber
470d5932 46 void CluCreate( ) {
47 if (fClu) return; //PH do not recreate existing containers
48 fClu=new TObjArray(7); for(Int_t i=0;i<7;i++)fClu->AddAt(new TClonesArray("AliHMPIDCluster"),i); }//create clusters list
d3da6dc4 49 void CluReset ( ) {if(fClu)for(int i=0;i<7;i++)fClu->At(i)->Clear(); }//clean clusters list
d3da6dc4 50protected:
51 TClonesArray *fSdi; //! list of sdigits
52 TObjArray *fDig; //! each chamber holds it's one list of digits
53 TObjArray *fClu; //! each chamber holds it's one list of clusters
54
1d4857c5 55private:
d3da6dc4 56 AliHMPID(const AliHMPID &rich );
57 AliHMPID& operator=(const AliHMPID&);
58
59 ClassDef(AliHMPID,11) //Main HMPID class
60};//class AliHMPID
cf7e313e 61
62typedef AliHMPID AliRICH; // for backward compatibility
63
d3da6dc4 64//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
65#endif