]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - TRD/AliTRDdigit.h
First round of effc++ changes
[u/mrichter/AliRoot.git] / TRD / AliTRDdigit.h
index 0fb30cc72f9fb88b4b54be5e3893e7822d7aa000..0b6fd9b39817eab6c5cf0b9c6936f98e9e64fc6e 100644 (file)
@@ -1,13 +1,17 @@
-#ifndef TRDdigit_h
-#define TRDdigit_h
+#ifndef ALITRDDIGIT_H
+#define ALITRDDIGIT_H
 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
  * See cxx source for full Copyright notice                               */
 
 /* $Id: AliTRDdigit.h,v */
 
-#include "AliDigitNew.h"
+///////////////////////////////////////////////////////////////////////////////
+//                                                                           //
+//  The TRD digit                                                            //
+//                                                                           //
+///////////////////////////////////////////////////////////////////////////////
 
-const UInt_t kRawDigit = 0x00000001;
+#include "AliDigitNew.h"
 
 //_____________________________________________________________________________
 class AliTRDdigit : public AliDigitNew {
@@ -15,27 +19,31 @@ class AliTRDdigit : public AliDigitNew {
  public:
 
   AliTRDdigit();
-  AliTRDdigit(Bool_t isRaw, Int_t *digits);
-  ~AliTRDdigit() {};
+  AliTRDdigit(Bool_t isRaw, Int_t *digits, Int_t *amp);
+  virtual ~AliTRDdigit();
 
-          Int_t GetAmp()      { if (TestBit(kRawDigit))
-                                  return DecodeAmp();
-                                else
-                                  return fAmp; };
-          Int_t GetDetector() { return fId;   };
-          Int_t GetRow()      { return fRow;  };
-          Int_t GetCol()      { return fCol;  };
-          Int_t GetTime()     { return fTime; };
+  static  UInt_t RawDigit()          { return fgkRawDigit; };
 
-          Int_t DecodeAmp()   { return 0;     };
+          Int_t  GetAmp() const      { if (TestBit(fgkRawDigit))
+                                         return DecodeAmp();
+                                       else
+                                         return fAmp; };
+          Int_t  GetDetector() const { return fId;   };
+          Int_t  GetRow() const      { return fRow;  };
+          Int_t  GetCol() const      { return fCol;  };
+          Int_t  GetTime() const     { return fTime; };
+
+  virtual Int_t  DecodeAmp() const;
 
  protected:
 
-  Int_t        fRow;        // Pad row number
-  Int_t        fCol;        // Pad col number
-  Int_t        fTime;       // Time bucket
+  static const UInt_t   fgkRawDigit; // Marks a raw digit
+
+               UShort_t fRow;        // Pad row number
+               UShort_t fCol;        // Pad col number
+               UShort_t fTime;       // Time bucket
 
-  ClassDef(AliTRDdigit,1)   // Digit for the TRD
+  ClassDef(AliTRDdigit,2)            // Digit for the TRD
 
 };