]> git.uio.no Git - u/mrichter/AliRoot.git/blob - CRT/AliCRThit.cxx
New methods and data member added by M. Horner.
[u/mrichter/AliRoot.git] / CRT / AliCRThit.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
16 /*
17 $Log$
18 Revision 1.1.4.3  2002/10/10 14:40:31  hristov
19 Updating VirtualMC to v3-09-02
20
21 Revision 1.5  2002/10/09 15:34:23  gamez
22 Bad Copy implementation on gcc-3.2 (Yves SCHUTZ)
23
24 Revision 1.4  2002/10/09 15:00:17  gamez
25 Bad operator= implementation on gcc-3.2 (Yves SCHUTZ)
26
27 Revision 1.3  2002/10/07 11:19:18  gamez
28 Changes requested by coding conventions
29
30 Revision 1.2  2002/07/25 21:27:22  gamez
31 Variables renamed to avoid floating exceptions
32
33 */
34
35 #include "AliCRThit.h"
36
37 ClassImp(AliCRThit)
38
39 //____________________________________________________________________________
40 AliCRThit::AliCRThit()
41 {
42    //
43    // default ctor for AliCRThit object
44    //
45
46   fId     = 0.;
47   fX      = 0.;
48   fY      = 0.;
49   fZ      = 0.;
50   fPx     = 0.;
51   fPy     = 0.;
52   fPz     = 0.;
53   fMedium = 0.;
54   fELoss  = 0.;
55   fCRTh = 0.;
56   fCRTMod = 0.;
57   fCRTMag = 0.;
58   fCRTRICH = 0.;
59   fCRTTPC = 0.;
60
61   fCopy = 0;
62   for (Int_t i = 0; i < 5; i++ ) {
63     fVolume[i] = 0;
64   }
65
66 }
67
68
69 //____________________________________________________________________________
70 AliCRThit::AliCRThit(const AliCRThit & hit)
71 {
72    //
73    // copy ctor
74    //
75
76   fId     = hit.fId;
77   fX      = hit.fX;
78   fY      = hit.fY;
79   fZ      = hit.fZ;
80   fPx     = hit.fPx;
81   fPy     = hit.fPy;
82   fPz     = hit.fPz;
83   fMedium = hit.fMedium;
84   fELoss  = hit.fELoss;
85   fCRTh = hit.fCRTh;
86   fCRTMod = hit.fCRTMod;
87   fCRTMag = hit.fCRTMag;
88   fCRTRICH = hit.fCRTRICH;
89   fCRTTPC = hit.fCRTTPC;
90
91   //fCopy = hit.fCopy;
92   //fVolume = hit.fVolume;
93
94 }
95
96 //_____________________________________________________________________________
97 AliCRThit& AliCRThit::operator= (const AliCRThit & hit)
98 {
99    //
100    // aisngment operator.
101    //
102
103   //fId     = hit.fId;
104   //fX      = hit.fX;
105   //fY      = hit.fY;
106   //fZ      = hit.fZ;
107   //fPx     = hit.fPx;
108   //fPy     = hit.fPy;
109   //fPz     = hit.fPz;
110   //fMedium = hit.fMedium;
111   //fELoss  = hit.fELoss;
112   //fCRTh = hit.fCRTh;
113   //fCRTMod = hit.fCRTMod;
114   //fCRTMag = hit.fCRTMag;
115   //fCRTRICH = hit.fCRTRICH;
116   //fCRTTPC = hit.fCRTTPC;
117
118   //fCopy = hit.fCopy;
119   //fVolume = hit.fVolume;
120
121   return *this;
122 }
123
124 //_____________________________________________________________________________
125 AliCRThit::AliCRThit(Int_t shunt, Int_t track, Int_t *vol,
126                      Float_t *hits) :AliHit(shunt, track)
127 {
128 //
129 // Constructor of hit object
130 //
131
132   fId     = hits[0];
133   fX      = hits[1];
134   fY      = hits[2];
135   fZ      = hits[3];
136   fPx     = hits[4];
137   fPy     = hits[5];
138   fPz     = hits[6];
139   fMedium = hits[7];
140   fELoss  = hits[8];
141   fCRTh = hits[9];
142   fCRTMod = hits[10];
143   fCRTMag = hits[11];
144   fCRTRICH = hits[12];
145   fCRTTPC = hits[13];
146
147   //fTrack = (Int_t)hits[9];
148
149   for (Int_t i = 0; i < 5 ; i++ ) {
150     fVolume[i] = vol[i];
151   }
152
153 }
154