Merging the VirtualMC branch to the main development branch (HEAD)
[u/mrichter/AliRoot.git] / CRT / AliCRThit.cxx
CommitLineData
fb7a1f55 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/*
c312f3f0 17$Log$
b9d0a01d 18Revision 1.1.4.3 2002/10/10 14:40:31 hristov
19Updating VirtualMC to v3-09-02
20
21Revision 1.5 2002/10/09 15:34:23 gamez
22Bad Copy implementation on gcc-3.2 (Yves SCHUTZ)
23
1d2f436b 24Revision 1.4 2002/10/09 15:00:17 gamez
25Bad operator= implementation on gcc-3.2 (Yves SCHUTZ)
26
6a65acdc 27Revision 1.3 2002/10/07 11:19:18 gamez
28Changes requested by coding conventions
29
fa15ea42 30Revision 1.2 2002/07/25 21:27:22 gamez
31Variables renamed to avoid floating exceptions
fb7a1f55 32
33*/
34
35#include "AliCRThit.h"
36
37ClassImp(AliCRThit)
38
39//____________________________________________________________________________
fa15ea42 40AliCRThit::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//____________________________________________________________________________
fb7a1f55 70AliCRThit::AliCRThit(const AliCRThit & hit)
71{
72 //
fa15ea42 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
1d2f436b 91 //fCopy = hit.fCopy;
92 //fVolume = hit.fVolume;
fa15ea42 93
94}
95
96//_____________________________________________________________________________
97AliCRThit& AliCRThit::operator= (const AliCRThit & hit)
98{
99 //
100 // aisngment operator.
fb7a1f55 101 //
102
6a65acdc 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;
fa15ea42 120
121 return *this;
fb7a1f55 122}
fa15ea42 123
124//_____________________________________________________________________________
fb7a1f55 125AliCRThit::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
fa15ea42 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
fb7a1f55 153}
154