]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - MUON/AliMUONChamber.h
Changes needed on Sun with Root v4-03-04
[u/mrichter/AliRoot.git] / MUON / AliMUONChamber.h
index 1565cca43794b24ac60b7bef659094f0064924bf..70f61d61b6ceabc3dd648b72bc6146858c3b020b 100644 (file)
@@ -4,56 +4,62 @@
  * See cxx source for full Copyright notice                               */
 
 /* $Id$ */
+// Revision of includes 07/05/2004
+
+#include <TObject.h>
+#include <TObjArray.h>
 
-#include "TObjArray.h"
 #include "AliSegmentation.h"
 #include "AliMUONResponse.h"
+#include "AliMUONGeometrySegmentation.h"
 
 class AliMUONClusterFinderVS;
-//class AliMUONResponse ;
-//class AliSegmentation ;
+class AliMUONGeometryModule;
+class AliMUON;
+class AliMUONHit;
+
 
-class AliMUONChamber:
-public TObject
+class AliMUONChamber : public TObject
 {
  public:
     AliMUONChamber();
     AliMUONChamber(Int_t id);
-    AliMUONChamber(const AliMUONChamber & rChamber);
     virtual ~AliMUONChamber();
     
 //
-// Get GEANT id of sensitive volume
-  virtual Int_t   GetGid() {return fGid;}
-// Set GEANT id of sensitive volume
-  virtual void    SetGid(Int_t id) {fGid=id;}
-//  
+// Get chamber Id
+  virtual Int_t   GetId() const {return fId;}
+//
+
+// Get chamber Id
+  virtual Bool_t  IsSensId(Int_t volId) const;
+  
 // Initialisation
   virtual void    Init();
+  virtual void    Init(Int_t flag);
 // Set z-position of chamber  
   virtual void    SetZ(Float_t Z) {fZ = Z;}
 // Get z-position of chamber  
-  virtual Float_t Z(){return fZ;}
+  virtual Float_t Z() const {return fZ;}
 // Set inner radius of sensitive volume 
   virtual void SetRInner(Float_t rmin) {frMin=rmin;}
 // Set outer radius of sensitive volum  
   virtual void SetROuter(Float_t rmax) {frMax=rmax;}  
 
 // Return inner radius of sensitive volume 
-  virtual  Float_t RInner()            {return frMin;}
+  virtual  Float_t RInner() const      {return frMin;}
 // Return outer radius of sensitive volum  
-  virtual Float_t ROuter()            {return frMax;}  
+  virtual Float_t ROuter() const       {return frMax;}  
 //  
 // Set response model
   virtual void    SetResponseModel(AliMUONResponse* thisResponse) {fResponse=thisResponse;}
 //  
 // Set segmentation model
-  virtual void    SetSegmentationModel(Int_t i, AliSegmentation* thisSegmentation) {
-      (*fSegmentation)[i-1] = thisSegmentation;
+  virtual void    SetSegmentationModel(Int_t isec, AliSegmentation* thisSegmentation) {
+      fSegmentation->AddAt(thisSegmentation,isec-1);
   }
-// Set Cluster reconstruction model  
-  virtual void    SetReconstructionModel(AliMUONClusterFinderVS *thisReconstruction) {
-      fReconstruction = thisReconstruction;
+  virtual void    SetSegmentationModel(Int_t isec, AliMUONGeometrySegmentation* thissegmentation) {
+      fSegmentation2->AddAt(thissegmentation,isec-1);
   }
 //  
 //  Get pointer to response model
@@ -64,10 +70,13 @@ public TObject
       return (AliSegmentation *) (*fSegmentation)[isec-1];
   }
   virtual TObjArray* ChamberSegmentation() {return fSegmentation;}
-//  Get pointer to cluster reconstruction model
-  virtual AliMUONClusterFinderVS* &ReconstructionModel(){return fReconstruction;}
+
+  virtual AliMUONGeometrySegmentation*  SegmentationModel2(Int_t isec) {
+      return (AliMUONGeometrySegmentation*) (*fSegmentation2)[isec-1];
+  }
+
 // Get number of segmentation sectors  
-  virtual Int_t Nsec()              {return fnsec;}
+  virtual Int_t Nsec() const        {return fnsec;}
 // Set number of segmented cathodes (1 or 2)  
   virtual void  SetNsec(Int_t nsec) {fnsec=nsec;}
 //
@@ -78,9 +87,11 @@ public TObject
 //  
 // Ask segmentation if signal should be generated  
   virtual Int_t   SigGenCond(Float_t x, Float_t y, Float_t z);
+  virtual Int_t   SigGenCond(AliMUONHit* hit);
 //
 // Initialisation of segmentation for hit  
   virtual void    SigGenInit(Float_t x, Float_t y, Float_t z);
+  virtual void    SigGenInit(AliMUONHit* hit);
 // Initialisation of charge fluctuation for given hit
   virtual void    ChargeCorrelationInit();
 
@@ -105,22 +116,30 @@ public TObject
   virtual void   DisIntegration(Float_t eloss, Float_t tof,
                                Float_t xhit, Float_t yhit, Float_t zhit,
                                Int_t& x, Float_t newclust[6][500]);
+  virtual void   DisIntegration(AliMUONHit* hit,
+                               Int_t& x, Float_t newclust[6][500]);
 // Initialize geometry related parameters  
   virtual void    InitGeo(Float_t z);
 //
-  virtual Float_t DGas() {return fdGas;}
-  virtual Float_t DAlu() {return fdAlu;}  
+  virtual Float_t DGas() const {return fdGas;}
+  virtual Float_t DAlu() const {return fdAlu;}  
   virtual void SetDGas(Float_t DGas) {fdGas = DGas;}
   virtual void SetDAlu(Float_t DAlu) {fdAlu = DAlu;}  
   virtual void SetChargeCorrel(Float_t correl) {fResponse->SetChargeCorrel(correl);}
-// assignment operator  
-  AliMUONChamber& operator =(const AliMUONChamber& rhs);
+
+// geometry  
+  void SetGeometry(AliMUONGeometryModule* geometry) {fGeometry = geometry;}
+  AliMUONGeometryModule* GetGeometry() const {return fGeometry; }
+
   
  protected:
+  AliMUONChamber(const AliMUONChamber & rChamber);
+  // assignment operator  
+  AliMUONChamber& operator =(const AliMUONChamber& rhs);
+
   Int_t   fId;   // chamber number
   Float_t fdGas; // half gaz gap
   Float_t fdAlu; // half Alu width  
-  Int_t   fGid;  // GEANT volume if for sensitive volume of this chamber
   Float_t fZ;    // Z position (cm)
   Int_t   fnsec; // number of semented cathode planes
   Float_t frMin; // innermost sensitive radius
@@ -128,9 +147,12 @@ public TObject
   Float_t fCurrentCorrel; //! charge correlation for current hit.
 
   TObjArray              *fSegmentation;    // pointer to segmentation
-  AliMUONClusterFinderVS *fReconstruction;  // pointer to reconstruction
+  TObjArray              *fSegmentation2;   // pointer to geometry segmentation bending & NBending
+
   AliMUONResponse        *fResponse;        // pointer to response
-  ClassDef(AliMUONChamber,1) // Muon tracking chamber class
+  AliMUONGeometryModule  *fGeometry;        // pointer to geometry
+  AliMUON                *fMUON;            // pointer to MUON
+  ClassDef(AliMUONChamber,3) // Muon tracking chamber class
 };
 
 #endif