]> git.uio.no Git - u/mrichter/AliRoot.git/blob - ITS/AliITSMapA1.h
A new method DrawPMDModule is added
[u/mrichter/AliRoot.git] / ITS / AliITSMapA1.h
1 #ifndef ALIITSMAPA1_H
2 #define ALIITSMAPA1_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice     */
5 /* $Id$ */
6 ////////////////////////////////////////////////////////////////////////
7 //  Map Class for ITS. Implementation A1. In this implementation, the //
8 // 2 dimensional (iz,ix) map is filled with integers values. For each //
9 // cell a corresponding TObject, a hit, can also be stored.           //
10 ////////////////////////////////////////////////////////////////////////
11 #include "AliITSMap.h"
12 #include "TArrayI.h"
13
14 class AliITSsegmentation;
15 class TObjArray;
16
17 class AliITSMapA1 : public AliITSMap{
18
19  public:
20     AliITSMapA1(); // default creator
21     // Standard reator using only a segmentation class
22     AliITSMapA1(AliITSsegmentation *seg);
23     // Standard reator using only a segmentation class and pointer to digits
24     AliITSMapA1(AliITSsegmentation *seg, TObjArray *dig);
25     // Standard reator using only a segmentation class and pointer to digits
26     // and a threshold value
27     AliITSMapA1(AliITSsegmentation *seg, TObjArray *dig, Int_t thr);
28     AliITSMapA1(AliITSsegmentation *seg, TObjArray *dig, TArrayI thr);
29     // Copy Operator
30     AliITSMapA1(const AliITSMapA1 &source);
31     // Assignment operator
32     AliITSMapA1& operator=(const AliITSMapA1 &source);
33     // Distructor
34     virtual ~AliITSMapA1();
35     // Fill hits from list of digits into hit map
36     virtual  void  FillMap();
37     virtual  void  FillMap2();
38     // Clear the hit map
39     virtual  void  ClearMap();    
40     // Set a single hit
41     virtual  void  SetHit(Int_t iz, Int_t ix, Int_t idigit);
42     // Set threshold for the signal
43     virtual  void  SetThreshold(Int_t thresh) {fMapThreshold=thresh;}
44     virtual  void  SetThresholdArr(TArrayI th) {fMapThresholdArr=th;} 
45     // Delete a single hit
46     virtual  void  DeleteHit(Int_t iz, Int_t ix);
47     // Get index of hit in the list of digits
48     virtual Int_t  GetHitIndex(Int_t iz, Int_t ix) const ;
49     // Get pointer to digit
50     virtual TObject* GetHit(Int_t iz, Int_t ix) const;
51     // Flag a hit as used
52     virtual  void  FlagHit(Int_t iz, Int_t ix);
53     // Test hit status
54     virtual FlagType TestHit(Int_t iz, Int_t ix);
55     // Get signal from map
56     virtual Double_t  GetSignal(Int_t iz, Int_t ix) const;
57     // Get max index inmap
58     Int_t   MaxIndex() const  {return fMaxIndex;}
59     // Set the array of objects
60     void SetArray(TObjArray *obj);
61
62  protected:
63     // Check index
64     Int_t   CheckedIndex(Int_t iz, Int_t ix) const;
65
66     // Data members
67     AliITSsegmentation *fSegmentation;   // segmentation class
68     Int_t fNpx;                          // fNpx
69     Int_t fNpz;                          // fNpz
70     TObjArray  *fObjects;                // object
71     Int_t fNobjects;                     // number of objects
72     Int_t fMaxIndex;                     // max index in map
73     TArrayI fMapThresholdArr;            // array with thresholds
74  private:
75     Int_t *fHitMap;                      //! [fMaxIndex]
76     Int_t fMapThreshold;                 // signal threshold (ADC)
77
78     ClassDef(AliITSMapA1,2)  // Implements Hit/Digit Map 
79 };
80
81 #endif  
82