BOSS 7.1.1
BESIII Offline Software System
Loading...
Searching...
No Matches
DstTofTrack.cxx
Go to the documentation of this file.
3/*
4 the following code maybe cause
5 DstEvent and RecEvent use each other
6 to avoid conflict, comment it
7
8#include "TofRecEvent/RecBTofTrack.h"
9#include "TofRecEvent/RecETofTrack.h"
10
11class RecBTofTrack ;
12class RecETofTrack ;
13
14*/
15
17
18 m_tofTrackID = -1;
19 m_trackID = -1;
20 m_tofID = -1;
21 m_status = -1;
22 m_path = 9999.0;
23 m_zrhit = 9999.0;
24 m_ph = 9999.0;
25 m_tof = 9999.0;
26 m_beta = 9999.0;
27 for( int i=0; i<6; i++ ) {
28 m_toffset[i] = 9999.0;
29 m_sigma[i] = 9999.0;
30 }
31 m_quality = 10;
32 m_t0 = 0.0;
33 m_errt0 = 0.0;
34
35 m_errz = 9999.0;
36 m_phi = 9999.0;
37 m_errphi = 9999.0;
38 m_energy = 9999.0;
39 m_errenergy = 9999.0;
40
41}
42
43
45 if( m_tofID < 0 ) return m_tofID;
46 if( TofHitStatus::is_mrpc( m_status ) ) {
47 return static_cast<int>( m_tofID/12 );
48 }
49 else {
50 return m_tofID;
51 }
52 return -1;
53}
54
55
57 if( m_tofID<0 ) return -1;
58 if( TofHitStatus::is_mrpc( m_status ) ) {
59 return static_cast<int>( m_tofID%12 );
60 }
61 return -1;
62}
63
64
65/*
66DstTofTrack&
67DstTofTrack::operator=(const RecBTofTrack& source){
68
69 m_tofTrackID = source.m_tofTrackID;
70 m_trackID = source.m_trackID;
71 m_tofID = source.m_tofID;
72 m_status = source.m_status;
73 m_path = source.m_path;
74 m_zrhit = source.m_zrhit;
75 m_ph = source.m_ph;
76 m_tof = source.m_tof;
77 m_beta = source.m_beta;
78 for( int i=0; i<6; i++ ) {
79 m_toffset[i] = source.m_toffset[i];
80 m_sigma[i] = source.m_sigma[i];
81 }
82 m_quality = source.m_quality;
83 m_t0 = source.m_t0;
84 m_errt0 = source.m_errt0;
85
86 m_errz = source.m_errz;
87 m_phi = source.m_phi;
88 m_errphi = source.m_errphi;
89 m_errenergy = source.m_errenergy;
90
91 return *this;
92}
93
94
95void
96DstTofTrack::copy(const RecBTofTrack* orig) {
97
98 m_tofTrackID = orig->m_tofTrackID;
99 m_trackID = orig->m_trackID;
100 m_tofID = orig->m_tofID;
101 m_status = orig->m_status;
102 m_path = orig->m_path;
103 m_zrhit = orig->m_zrhit;
104 m_ph = orig->m_ph;
105 m_tof = orig->m_tof;
106 m_beta = orig->m_beta;
107 for( int i=0; i<6; i++ ) {
108 m_toffset[i] = orig->m_toffset[i];
109 m_sigma[i] = orig->m_sigma[i];
110 }
111 m_quality = orig->m_quality;
112 m_t0 = orig->m_t0;
113 m_errt0 = orig->m_errt0;
114
115 m_errz = orig->m_errz;
116 m_phi = orig->m_phi;
117 m_errphi = orig->m_errphi;
118 m_errenergy = orig->m_errenergy;
119}
120
121
122DstTofTrack::DstTofTrack(const RecBTofTrack& source) {
123
124 m_tofTrackID = source.m_tofTrackID;
125 m_trackID = source.m_trackID;
126 m_tofID = source.m_tofID;
127 m_status = source.m_status;
128 m_path = source.m_path;
129 m_zrhit = source.m_zrhit;
130 m_ph = source.m_ph;
131 m_tof = source.m_tof;
132 m_beta = source.m_beta;
133 for( int i=0; i<6; i++ ) {
134 m_toffset[i] = source.m_toffset[i];
135 m_sigma[i] = source.m_sigma[i];
136 }
137 m_quality = source.m_quality;
138 m_t0 = source.m_t0;
139 m_errt0 = source.m_errt0;
140
141 m_errz = source.m_errz;
142 m_phi = source.m_phi;
143 m_errphi = source.m_errphi;
144 m_errenergy = source.m_errenergy;
145}
146
147
148DstTofTrack&
149DstTofTrack::operator=(const RecETofTrack& source){
150
151 m_tofTrackID = source.m_tofTrackID;
152 m_trackID = source.m_trackID;
153 m_tofID = source.m_tofID;
154 m_status = source.m_status;
155 m_path = source.m_path;
156 m_zrhit = source.m_zrhit;
157 m_ph = source.m_ph;
158 m_tof = source.m_tof;
159 m_beta = source.m_beta;
160 for( int i=0; i<6; i++ ) {
161 m_toffset[i] = source.m_toffset[i];
162 m_sigma[i] = source.m_sigma[i];
163 }
164 m_quality = source.m_quality;
165 m_t0 = source.m_t0;
166 m_errt0 = source.m_errt0;
167
168 m_errz = source.m_errz;
169 m_phi = source.m_phi;
170 m_errphi = source.m_errphi;
171 m_errenergy = source.m_errenergy;
172
173 return *this;
174}
175
176
177void
178DstTofTrack::copy(const RecETofTrack* orig) {
179
180 m_tofTrackID = orig->m_tofTrackID;
181 m_trackID = orig->m_trackID;
182 m_tofID = orig->m_tofID;
183 m_status = orig->m_status;
184 m_path = orig->m_path;
185 m_zrhit = orig->m_zrhit;
186 m_ph = orig->m_ph;
187 m_tof = orig->m_tof;
188 m_beta = orig->m_beta;
189 for( int i=0; i<6; i++ ) {
190 m_toffset[i] = orig->m_toffset[i];
191 m_sigma[i] = orig->m_sigma[i];
192 }
193 m_quality = orig->m_quality;
194 m_t0 = orig->m_t0;
195 m_errt0 = orig->m_errt0;
196
197 m_errz = orig->m_errz;
198 m_phi = orig->m_phi;
199 m_errphi = orig->m_errphi;
200 m_errenergy = orig->m_errenergy;
201}
202
203
204DstTofTrack::DstTofTrack(const RecETofTrack& source) {
205
206 m_tofTrackID = source.m_tofTrackID;
207 m_trackID = source.m_trackID;
208 m_tofID = source.m_tofID;
209 m_status = source.m_status;
210 m_path = source.m_path;
211 m_zrhit = source.m_zrhit;
212 m_ph = source.m_ph;
213 m_tof = source.m_tof;
214 m_beta = source.m_beta;
215 for( int i=0; i<6; i++ ) {
216 m_toffset[i] = source.m_toffset[i];
217 m_sigma[i] = source.m_sigma[i];
218 }
219 m_quality = source.m_quality;
220 m_t0 = source.m_t0;
221 m_errt0 = source.m_errt0;
222
223 m_errz = source.m_errz;
224 m_phi = source.m_phi;
225 m_errphi = source.m_errphi;
226 m_errenergy = source.m_errenergy;
227}
228*/
bool is_mrpc() const