#include <TBranch.h> // used in inline function SetHitsAddressBranch
#include "AliRun.h"
+#include "AliLoader.h"
#include "AliDetector.h"
+#include "AliITSDetType.h"
class TString;
class TTree;
class TFile;
-class AliITSDetType;
+//class AliITSDetType;
class AliITSsimulation;
class AliITSClusterFinder;
+class AliITSLoader;
class AliITSsegmentation;
class AliITSresponse;
class AliITShit;
AliITS(); // Default creator.
AliITS(const char *name, const char *title); // standard Creator
virtual ~AliITS(); // destructor
- AliITS(AliITS &source); // copy constructor. Not to be used!
+ AliITS(const AliITS &source); // copy constructor. Not to be used!
AliITS& operator=(AliITS &source); // = operator. Not to be used!
virtual Int_t IsVersion() const {return 1;}
- virtual Int_t DistancetoPrimitive(Int_t px, Int_t py);
+ virtual Int_t DistancetoPrimitive(Int_t px, Int_t py) const;
//===================== Simulation Geometry ========================
// get geometry version - detailed (major) or coarse (minor)
- virtual Int_t GetMajorVersion(){return -1;}
- virtual Int_t GetMinorVersion(){return -1;}
+ virtual Int_t GetMajorVersion() const {return -1;}
+ virtual Int_t GetMinorVersion() const {return -1;}
virtual void GetGeometryVersion(Int_t &a,Int_t &b)
{a = GetMajorVersion();b=GetMinorVersion();return;}
- virtual void SetEUCLID(Bool_t euclid=1) {fEuclidOut = euclid;}
+ virtual void SetEUCLID(Bool_t euclid=kTRUE) {fEuclidOut = euclid;}
//-------------------- Geometry Transformations --------------------
// ITS geometry functions
AliITSgeom *GetITSgeom() const {return fITSgeom;}
AliITSmodule *GetModule(Int_t index) {return (AliITSmodule *)
(fITSmodules->At(index));}
- //================ Nessesary general Classes =======================
+ //================ Necessary general Classes =======================
virtual void Init();
+ virtual AliLoader* MakeLoader(const char* topfoldername);
virtual void SetDefaults();
virtual void SetDefaultSimulation();
virtual void SetDefaultClusterFinders();
- virtual void MakeBranch(Option_t *opt=" ", const char *file=0);
+ virtual void MakeBranch(Option_t *opt=" ");
virtual void SetTreeAddress();
- // For a give branch from the treeH sets the TClonesArray address.
- virtual void SetHitsAddressBranch(TBranch *b){b->SetAddress(&fHits);}
+ // For a given branch from the treeH sets the TClonesArray address.
+ virtual void SetHitsAddressBranch(TBranch *b) {b->SetAddress(&fHits);}
// Return pointer to DetType #id
AliITSDetType *DetType(Int_t id);
//Int_t NDetTypes() {return fNDetTypes;}
virtual void SetSegmentationModel(Int_t id, AliITSsegmentation *seg);
// Set simulation - temporary
virtual void SetSimulationModel(Int_t id, AliITSsimulation *sim);
+ // Set simulation - temporary
+ virtual AliITSsimulation* GetSimulationModel(Int_t id){
+ return ((AliITSDetType*)(fDetTypes->At(id)))->GetSimulationModel();}
// Set reconstruction
virtual void SetReconstructionModel(Int_t id, AliITSClusterFinder *rec);
// Set class names for digit and rec point
virtual void AddHit(Int_t track, Int_t *vol, Float_t *hits);
//------------ sort hits by module for Digitisation ----------------
virtual void InitModules(Int_t size,Int_t &nmodules);
+ virtual void FillModules(TTree *treeH, Int_t mask = 0);
virtual void FillModules(Int_t evnt,Int_t bgrev,Int_t nmodules,
Option_t *opt,Text_t *filename);
virtual void ClearModules();
void SetTreeAddressD(TTree *treeD);
void Hits2SDigits(); // Turn hits into SDigits
void Hits2PreDigits(); // Turn hits into SDigits
+ AliDigitizer* CreateDigitizer(AliRunDigitizer* manager) const;
void SDigits2Digits(){SDigitsToDigits("All");} // Turn SDigits to Digits
void SDigitsToDigits(Option_t *opt="All"); // Turn SDigits to Digits
void Hits2Digits(); // Turn hits straight into Digits.
void AddCluster(Int_t branch, AliITSRawCluster *c);
void ResetClusters(); // one of the methods in
void ResetClusters(Int_t branch); // the pair will be kept
- // Return pointer to the tree of clusters
- TTree *TreeC() {return fTreeC;}
// Return pointers to clusters
TObjArray *Ctype() {return fCtype;}
Int_t *Nctype() {return fNctype;}
{return ((TClonesArray *) (*fCtype)[id]);}
//=================== Reconstruction ===============================
- void MakeBranchR(const char *file);
+ void MakeBranchR(const char *file, Option_t *opt=" ");
+ void MakeBranchRF(const char *file){MakeBranchR(file,"Fast");}
+ void MakeBranchC();
void SetTreeAddressR(TTree *treeR);
void AddRecPoint(const AliITSRecPoint &p);
void HitsToFastRecPoints(Int_t evNumber,Int_t bgrev,Int_t size,
void ResetRecPoints();
// Return pointer to rec points
TClonesArray *RecPoints() {return fRecPoints;}
-
+
protected:
//================== Data Members ==================================
AliITSgeom *fITSgeom; // Pointer to ITS geometry
Int_t fNDetTypes; // Number of detector types
TObjArray *fDetTypes; // List of detector types
- TClonesArray *fSDigits; // List of Summable digits.
+ TClonesArray *fSDigits; //! List of Summable digits.
Int_t fNSDigits; // Number of Summable Digits.
- TObjArray *fDtype; // List of digits
+ TObjArray *fDtype; //! List of digits
Int_t *fNdtype; //[fNDetTypes] Num. of digits per type of det.
- TObjArray *fCtype; // List of clusters
+ TObjArray *fCtype; //! List of clusters
Int_t *fNctype; //[fNDetTypes] Num. of clust. per type of det.
- TTree *fTreeC; // Tree for raw clusters
- TClonesArray *fRecPoints; // List of reconstructed points
+ TClonesArray *fRecPoints; //! List of reconstructed points
Int_t fNRecPoints; // Number of rec points
- ClassDef(AliITS,1) // Base class for ITS
+ ClassDef(AliITS,3) // Base class for ITS
};
#endif