]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PHOS/AliPHOSv2.cxx
New detector numbering scheme (common for DAQ/HLT/Offline). All the subdetectors...
[u/mrichter/AliRoot.git] / PHOS / AliPHOSv2.cxx
1 /**************************************************************************
2  * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3  *                                                                        *
4  * Author: The ALICE Off-line Project.                                    *
5  * Contributors are mentioned in the code where appropriate.              *
6  *                                                                        *
7  * Permission to use, copy, modify and distribute this software and its   *
8  * documentation strictly for non-commercial purposes is hereby granted   *
9  * without fee, provided that the above copyright notice appears in all   *
10  * copies and that both the copyright notice and this permission notice   *
11  * appear in the supporting documentation. The authors make no claims     *
12  * about the suitability of this software for any purpose. It is          *
13  * provided "as is" without express or implied warranty.                  *
14  **************************************************************************/
15 /* $Id$ */
16
17 /* History of cvs commits:
18  *
19  * $Log$
20  */
21
22 //_________________________________________________________________________
23 // Version of AliPHOSv1 which keeps all hits in TreeH
24 // AddHit, StepManager,and FinishEvent are redefined 
25 //                  
26 //*-- Author: Gines MARTINEZ (SUBATECH)
27 //*-- Modified Nov. 22 2000 by Dmitri Peressounko
28 // All hits are stored.
29 // Note, that primaries will not be assigned to digits:
30 // because of tiny energy deposition at each step.
31 //  
32
33 // --- ROOT system ---
34 #include "TClonesArray.h"
35
36 // --- Standard library ---
37
38
39 // --- AliRoot header files ---
40
41 #include "AliPHOSv2.h"
42 #include "AliPHOSHit.h"
43
44 ClassImp(AliPHOSv2)
45
46 //____________________________________________________________________________
47 AliPHOSv2::AliPHOSv2()
48 {
49   // default ctor
50
51 }
52
53 //____________________________________________________________________________
54 AliPHOSv2::AliPHOSv2(const char *name, const char *title):
55 AliPHOSv1(name,title)
56 {
57   // ctor
58 }
59 //__________________________________________________________________________
60 AliPHOSv2::~AliPHOSv2()
61 {
62   // dtor
63 }
64
65 //____________________________________________________________________________
66 void AliPHOSv2::Copy(TObject & phos)const
67 {
68   TObject::Copy(phos) ; 
69   AliPHOSv1::Copy(phos) ;   
70 }
71
72 //____________________________________________________________________________
73 void AliPHOSv2::AddHit(Int_t shunt, Int_t primary, Int_t Id, Float_t * hits)
74 {
75   // Add a hit to the hit list.
76
77   AliPHOSHit *newHit ;
78
79   newHit = new AliPHOSHit(shunt, primary, Id, hits) ;
80
81   new((*fHits)[fNhits]) AliPHOSHit(*newHit) ;    
82   fNhits++ ;
83
84   delete newHit;
85
86 }
87
88