]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TOF/AliTOFDigitMap.h
Adding useful print out in case of issues
[u/mrichter/AliRoot.git] / TOF / AliTOFDigitMap.h
CommitLineData
bf6bf84c 1#ifndef ALITOFDIGITMAP_H
2#define ALITOFDIGITMAP_H
3
4/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
5 * See cxx source for full Copyright notice */
6
7
0e46b9ae 8//////////////////////////////////////////////////////////////
9// //
10// AliTOFDigitMap class //
11// //
12// digitmap enables fast check if the pad was already hit //
13// //
14// Author: F. Pierella | pierella@bo.infn.it //
15// //
d0eb8f39 16// Modified by A. De Caro | decaro@sa.infn.it //
17// //
0e46b9ae 18//////////////////////////////////////////////////////////////
bf6bf84c 19
bf6bf84c 20#include "TObject.h"
0e46b9ae 21
22#include "AliHitMap.h"
d3c7bfac 23
bf6bf84c 24class AliTOFDigitMap : public TObject
25{
26 public:
27 AliTOFDigitMap();
bf6bf84c 28 AliTOFDigitMap(const AliTOFDigitMap & digitMap);
29
30 virtual ~AliTOFDigitMap();
d0eb8f39 31
32 // Clear the digit map
33 virtual void Clear(const Option_t* opt = "");
34 // Add a single digit
35 void AddDigit(Int_t *vol, Int_t idigit);
36
37 // Get index of digit in the cell labelled by vol
38 Int_t GetDigitIndex(Int_t *vol, Int_t index) const;
39 // Get indices of digits in the cell labelled by vol
40 void GetDigitIndex(Int_t *vol, Int_t *index) const;
41
42 // Test digit status
43 virtual FlagType TestDigit(Int_t *vol) const;
44
bf6bf84c 45 // Assignment operator
46 AliTOFDigitMap& operator = (const AliTOFDigitMap& rhs);
47
ec5fb3e4 48 Int_t GetFilledCellNumber() const;
49 Bool_t StripDigitCheck(Int_t iSector, Int_t iPlate, Int_t iStrip) const;
818b5e8c 50 Int_t DigitInStrip(Int_t iSector, Int_t iPlate, Int_t iStrip) const;
d7ed6a6d 51 Int_t FilledCellsInStrip(Int_t iSector, Int_t iPlate, Int_t iStrip) const;
818b5e8c 52 void ResetDigitNumber(Int_t *vol, Int_t dig);
ec5fb3e4 53 void ResetDigit(Int_t *vol, Int_t dig);
54 void ResetDigit(Int_t *vol);
818b5e8c 55 Int_t GetNumberOfDigits(Int_t *vol);
dfa56f14 56
d0eb8f39 57 enum {
cc7a1acd 58 kMaxDigitsPerPad = 10
d0eb8f39 59 };
60
2dc6d650 61 private:
62 // Check index
0e74c396 63 Int_t CheckedIndex(Int_t * const vol) const;
2dc6d650 64
bf6bf84c 65 Int_t fNSector; // Number of sectors
66 Int_t fNplate; // Number of plates
67 Int_t fNstrip; // Maximum number of strips
68 Int_t fNpx; // Number of pads in x
a06668b9 69 Int_t fNpz; // Number of pads in z
bf6bf84c 70
bf6bf84c 71 Int_t fMaxIndex; // maximum index in hit map
d0eb8f39 72 Int_t **fDigitMap; // ! [fMaxIndex][kMaxDigitsPerPad]
d3c7bfac 73
10056aa6 74 ClassDef(AliTOFDigitMap,2) // Implements DigitMap as a 1-dim array
bf6bf84c 75};
76#endif