3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
8 /* History of cvs commits:
13 //_________________________________________________________________________
16 // 3 identifiers for the primary particle(s) at the origine of the digit
17 // The digits are made in FinishEvent() by summing all the hits in a single PHOS crystal or PPSD gas cell
18 // It would be nice to replace the 3 identifiers by an array, but, because digits are kept in a TClonesArray,
19 // it is not possible to stream such an array... (beyond my understqnding!)
21 //*-- Author: Laurent Aphecetche & Yves Schutz (SUBATECH)
23 // --- ROOT system ---
25 //#include "TObject.h"
27 // --- Standard library ---
29 // --- AliRoot header files ---
31 #include "AliDigitNew.h"
33 class AliPHOSDigit : public AliDigitNew {
35 friend ostream& operator << ( ostream& , const AliPHOSDigit&) ;
40 AliPHOSDigit(Int_t primary, Int_t id, Int_t DigEnergy, Float_t Time, Int_t index = -1) ;
41 AliPHOSDigit(const AliPHOSDigit & digit) ;
42 virtual ~AliPHOSDigit() ;
44 Bool_t operator==(const AliPHOSDigit &rValue) const;
45 AliPHOSDigit& operator+(AliPHOSDigit const &rValue) ;
46 AliPHOSDigit& operator*(Float_t factor) ;
47 // AliPHOSDigit& operator=(const AliPHOSDigit) {
48 // Fatal("operator = ", "not implemented") ; return *this ; }
49 Int_t Compare(const TObject * obj) const ;
50 Int_t GetNprimary() const { return fNprimary ; }
51 Int_t GetPrimary(Int_t index) const ;
52 Float_t GetTime(void) const {return fTime ;}
53 Float_t GetTimeR(void) const {return fTimeR ;}
54 Bool_t IsSortable() const { return kTRUE ; }
55 void Print(const Option_t * = "") const;
56 void SetAmp(Int_t Amp) { fAmp=Amp ; }
57 void SetTime(Float_t time) {fTime = time ;}
58 void SetTimeR(Float_t time) {fTimeR = time ;}
59 void ShiftPrimary(Int_t shift); // shift to separate different TreeK in merging
63 Int_t fNprimary ; // Number of primaries
64 Int_t * fPrimary ; //[fNprimary] Array of primaries
65 Float_t fTime ; // Calculcated time
66 Float_t fTimeR ; // Earliest time: to be used by Digits2Raw
68 ClassDef(AliPHOSDigit,3) // Digit in PHOS
72 #endif // ALIPHOSDIGIT_H