]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PHOS/AliPHOSDigit.h
AliITSgeom taken from AliITSLoader
[u/mrichter/AliRoot.git] / PHOS / AliPHOSDigit.h
CommitLineData
d15a28e7 1#ifndef ALIPHOSDIGIT_H
2#define ALIPHOSDIGIT_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
6ad0bfa0 6/* $Id$ */
7
702ab87e 8/* History of cvs commits:
9 *
10 * $Log$
27a73a5d 11 * Revision 1.33 2005/05/28 14:19:04 schutz
12 * Compilation warnings fixed by T.P.
13 *
702ab87e 14 */
15
b2a60966 16//_________________________________________________________________________
17// PHOS digit: Id
18// energy
19// 3 identifiers for the primary particle(s) at the origine of the digit
20// The digits are made in FinishEvent() by summing all the hits in a single PHOS crystal or PPSD gas cell
184569b0 21// It would be nice to replace the 3 identifiers by an array, but, because digits are kept in a TClonesArray,
b2a60966 22// it is not possible to stream such an array... (beyond my understqnding!)
23//
24//*-- Author: Laurent Aphecetche & Yves Schutz (SUBATECH)
d15a28e7 25
26// --- ROOT system ---
27
e957fea8 28//#include "TObject.h"
d15a28e7 29
30// --- Standard library ---
31
32// --- AliRoot header files ---
33
34#include "AliDigitNew.h"
35
36class AliPHOSDigit : public AliDigitNew {
6c370def 37
5cf7bbad 38 friend ostream& operator << ( ostream& , const AliPHOSDigit&) ;
6c370def 39
88714635 40 public:
41
cf239357 42 AliPHOSDigit() ;
9688c1dd 43 AliPHOSDigit(Int_t primary, Int_t id, Int_t DigEnergy, Float_t Time, Int_t index = -1) ;
27a73a5d 44 AliPHOSDigit(Int_t primary, Int_t id, Float_t energy , Float_t Time, Int_t index = -1) ;
cf239357 45 AliPHOSDigit(const AliPHOSDigit & digit) ;
2e5c3041 46 virtual ~AliPHOSDigit() ;
d15a28e7 47
b27d82c8 48 Bool_t operator==(const AliPHOSDigit &rValue) const;
d15a28e7 49 AliPHOSDigit& operator+(AliPHOSDigit const &rValue) ;
88cb7938 50 AliPHOSDigit& operator*(Float_t factor) ;
39da3d9b 51 // AliPHOSDigit& operator=(const AliPHOSDigit) {
52 // Fatal("operator = ", "not implemented") ; return *this ; }
037cc66d 53 Int_t Compare(const TObject * obj) const ;
27a73a5d 54 Int_t GetNprimary() const { return fNprimary ; }
26d4b141 55 Int_t GetPrimary(Int_t index) const ;
27a73a5d 56 Float_t GetEnergy(void) const {return fEnergy ;}
57 Float_t GetTime(void) const {return fTime ;}
58 Float_t GetTimeR(void) const {return fTimeR ;}
59 Bool_t IsSortable() const { return kTRUE ; }
702ab87e 60 void Print(const Option_t * = "") const;
27a73a5d 61 void SetAmp(Int_t Amp) {fAmp = Amp ;}
62 void SetEnergy(Float_t E) {fEnergy= E ;}
63 void SetTime(Float_t time) {fTime = time ;}
04f0bda3 64 void SetTimeR(Float_t time) {fTimeR = time ;}
88cb7938 65 void ShiftPrimary(Int_t shift); // shift to separate different TreeK in merging
26d4b141 66
88714635 67 private:
ff4c968a 68
27a73a5d 69 Int_t fNprimary ; // Number of primaries
adc232ca 70 Int_t * fPrimary ; //[fNprimary] Array of primaries
27a73a5d 71 Float_t fEnergy ; // Deposited energy in GeV
88cb7938 72 Float_t fTime ; // Calculcated time
04f0bda3 73 Float_t fTimeR ; // Earliest time: to be used by Digits2Raw
83974468 74
27a73a5d 75 ClassDef(AliPHOSDigit,4) // Digit in PHOS
d15a28e7 76
77} ;
78
79#endif // ALIPHOSDIGIT_H