]> git.uio.no Git - u/mrichter/AliRoot.git/blame_incremental - PHOS/AliPHOSDigit.h
Corrections to comply with coding convention
[u/mrichter/AliRoot.git] / PHOS / AliPHOSDigit.h
... / ...
CommitLineData
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
6/* $Id$ */
7
8//_________________________________________________________________________
9// PHOS digit: Id
10// energy
11// 3 identifiers for the primary particle(s) at the origine of the digit
12// The digits are made in FinishEvent() by summing all the hits in a single PHOS crystal or PPSD gas cell
13// It would be nice to replace the 3 identifiers by an array, but, because digits are kept in a TClonesQArray,
14// it is not possible to stream such an array... (beyond my understqnding!)
15//
16//*-- Author: Laurent Aphecetche & Yves Schutz (SUBATECH)
17
18// --- ROOT system ---
19
20#include "TObject.h"
21
22// --- Standard library ---
23
24// --- AliRoot header files ---
25
26#include "AliDigitNew.h"
27
28class AliPHOSDigit : public AliDigitNew {
29
30 public:
31
32 AliPHOSDigit() ;
33 AliPHOSDigit(Int_t primary, Int_t id, Int_t DigEnergy, Int_t index = -1) ;
34 AliPHOSDigit(const AliPHOSDigit & digit) ;
35 virtual ~AliPHOSDigit(){
36 // dtor
37 }
38
39 Bool_t operator==(AliPHOSDigit const &rValue) const;
40 AliPHOSDigit& operator+(AliPHOSDigit const &rValue) ;
41
42 friend class ostream& operator << ( ostream& , const AliPHOSDigit&) ;
43
44 Int_t Compare(TObject * obj) ;
45 Int_t GetNprimary() const {
46 // returns the number of primaries
47 return fNprimary ; }
48 Int_t GetPrimary(Int_t index) const ;
49 Bool_t IsSortable() const {
50 // says that AliPHOSDigits are sortable (needed for Sort method
51 return kTRUE ; }
52 void SetAmp(Int_t Amp) {
53 // sets the amplitude data member
54 fAmp=Amp ; }
55
56 private:
57
58 Int_t fPrimary1 ; // first primary (because objects in a TClonesArray bust have constant length)
59 Int_t fPrimary2 ; // second primary (because objects in a TClonesArray bust have constant lengt)
60 Int_t fPrimary3 ; // third primary (because objects in a TClonesArray bust have constant lengt)
61 Int_t fNprimary ; // Number of primaries
62
63 ClassDef(AliPHOSDigit,1) // Digit in PHOS
64
65} ;
66
67#endif // ALIPHOSDIGIT_H