X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=ZDC%2FAliZDCDigit.h;h=606bc9612879f5a404296ff72eca218d5d480cea;hb=4655c95e1fc70f425350268f53e11d4d0cff2a72;hp=c8e78910425840c4a9ab84c7e01dc6150c8fbde6;hpb=8a2624cc301a4bd98b89b9a157086ab802486d48;p=u%2Fmrichter%2FAliRoot.git diff --git a/ZDC/AliZDCDigit.h b/ZDC/AliZDCDigit.h index c8e78910425..606bc961287 100644 --- a/ZDC/AliZDCDigit.h +++ b/ZDC/AliZDCDigit.h @@ -23,21 +23,27 @@ class AliZDCDigit : public TObject { virtual ~AliZDCDigit() {} // Getters - const Int_t GetSector(Int_t i) {return fSector[i];} - const Int_t GetADCValue(Int_t i) {return fADCValue[i];} + Int_t GetSector(Int_t i) {return fSector[i];} + Int_t GetADCValue(Int_t i) {return fADCValue[i];} // Operators // Two digits are equal if they refers to the detector // in the same sub-volume (same procedure as for hits) - const Int_t operator == (AliZDCDigit &digit) { + Int_t operator == (AliZDCDigit &digit){ Int_t i; for(i=0; i<2; i++) if(fSector[i]!=digit.GetSector(i)) return 0; return 1; } // Adds the amplitude of digits - virtual AliZDCDigit& operator + (AliZDCDigit &digit) { + virtual AliZDCDigit operator + (AliZDCDigit &digit){ for(Int_t i = 0; i < 2; i++) fADCValue[i] += digit.fADCValue[i]; - return *this ; + return *this; + } + + // Print method + virtual void Print(Option_t *) const { + printf("\t AliZDCDigit -> Detector %d Quadrant %d: ADC HighGain= %d ADC LowGain= %d\n ", + fSector[0], fSector[1], fADCValue[0], fADCValue[1]); } protected: @@ -45,12 +51,6 @@ class AliZDCDigit : public TObject { //Data members Int_t fSector[2]; // Detector and tower in which light is produced Int_t fADCValue[2]; // ADC channel value (0 = high gain, 1 = low gain) - - // Print method - virtual void Print(Option_t *) const { - printf(" -> DIGIT: Detector = %d Quadrant = %d ADCCh high gain= %d ADCCh low gain= %d\n ", - fSector[0], fSector[1], fADCValue[0], fADCValue[1]); - } ClassDef(AliZDCDigit,4) // Digits in ZDC