BOSS 7.0.1
BESIII Offline Software System
Loading...
Searching...
No Matches
ExtTrackCnv.cxx
Go to the documentation of this file.
1#ifndef ExtTrackCnv_CXX
2#define ExtTrackCnv_CXX 1
3
4#include "GaudiKernel/MsgStream.h"
5#include "GaudiKernel/DataObject.h"
6#include "GaudiKernel/ObjectVector.h"
7
8#include "TClonesArray.h"
9
10#include "EventModel/EventModel.h"
11
12#include "DstEvent/DstEvent.h" //TDS object
13#include "DstEvent/DstExtTrack.h" //TDS object
14//#include "ExtEvent/ExtMucHit.h"
15#include "RootEventData/TExtTrack.h" // standard root object
16#include "RootEventData/TDstEvent.h"
17
18#include "RootCnvSvc/Dst/DstCnv.h"
19#include "RootCnvSvc/Dst/ExtTrackCnv.h"
20#include "RootCnvSvc/RootAddress.h"
21
22#include "CLHEP/Matrix/Vector.h"
23#include "CLHEP/Matrix/SymMatrix.h"
24#include "CLHEP/Vector/ThreeVector.h"
25
26#include "string.h"
27
28using namespace std;
29//using CLHEP::HepVector;
30using CLHEP::Hep3Vector;
31using CLHEP::HepSymMatrix;
32
33// Instantiation of a static factory class used by clients to create
34// instances of this service
35//static CnvFactory<ExtTrackCnv> s_factory;
36//const ICnvFactory& ExtTrackCnvFactory = s_factory;
37
38ExtTrackCnv::ExtTrackCnv(ISvcLocator* svc)
39: RootEventBaseCnv(classID(), svc)
40{
41 // Here we associate this converter with the /Event path on the TDS.
42 MsgStream log(msgSvc(), "ExtTrackCnv");
43 // log << MSG::DEBUG << "Constructor called for " << objType() << endreq;
44 m_rootBranchname ="m_extTrackCol";
45 //declareObject(EventModel::Dst::DstExtTrackCol, objType(), m_rootTreename, m_rootBranchname);
46 m_adresses.push_back(&m_extTrackCol);
47 m_extTrackCol=0;
48}
49
50StatusCode ExtTrackCnv::TObjectToDataObject(DataObject*& refpObject) {
51 // creation of TDS object from root object
52
53 MsgStream log(msgSvc(), "ExtTrackCnv");
54 log << MSG::DEBUG << "ExtTrackCnv::TObjectToDataObject" << endreq;
55 StatusCode sc=StatusCode::SUCCESS;
56
57 // create the TDS location for the ExtTrack Collection
58 DstExtTrackCol* extTrackTdsCol = new DstExtTrackCol;
59 refpObject=extTrackTdsCol;
60
61
62 // now convert
63 if (!m_extTrackCol) return sc;
64 TIter extTrackIter(m_extTrackCol);
65 TExtTrack *extTrackRoot = 0;
66 while ((extTrackRoot = (TExtTrack*)extTrackIter.Next())) {
67
68 int trackId = extTrackRoot->GetTrackId();
69 //Tof layer1:
70 double p1x = extTrackRoot->GetTof1PositionX();
71 double p1y = extTrackRoot->GetTof1PositionY();
72 double p1z = extTrackRoot->GetTof1PositionZ();
73 double m1x = extTrackRoot->GetTof1MomentumX();
74 double m1y = extTrackRoot->GetTof1MomentumY();
75 double m1z = extTrackRoot->GetTof1MomentumZ();
76 Hep3Vector tof1p(p1x,p1y,p1z);
77 Hep3Vector tof1m(m1x,m1y,m1z);
78
79 // char * pTof1 = extTrackRoot->GetTof1VolumeName().Data();
80 string v1s = extTrackRoot->GetTof1VolumeName().Data();
81 int v1n = extTrackRoot->GetTof1VolumeNumber() ;
82 double tof1= extTrackRoot->GetTof1();
83 double tof1path= extTrackRoot->GetTof1Path();
84 double z1 = extTrackRoot->GetTof1PosSigmaAlongZ();
85 double t1 = extTrackRoot->GetTof1PosSigmaAlongT();
86 double x1 = extTrackRoot->GetTof1PosSigmaAlongX();
87 double y1 = extTrackRoot->GetTof1PosSigmaAlongY();
88 HepSymMatrix e1m(6) ;
89 for (int i = 0;i<6 ;i++ )
90 for (int j= 0;j<6 ;j++ )
91 e1m[i][j]= extTrackRoot->GetTof1ErrorMatrix(i , j) ;
92
93 //Tof layer2:
94 double p2x = extTrackRoot->GetTof2PositionX() ;
95 double p2y = extTrackRoot->GetTof2PositionY() ;
96 double p2z = extTrackRoot->GetTof2PositionZ() ;
97 double m2x = extTrackRoot->GetTof2MomentumX() ;
98 double m2y = extTrackRoot->GetTof2MomentumY() ;
99 double m2z = extTrackRoot->GetTof2MomentumZ();
100 Hep3Vector tof2p(p2x,p2y,p2z);
101 Hep3Vector tof2m(m2x,m2y,m2z);
102
103 string v2s = extTrackRoot->GetTof2VolumeName().Data();
104 int v2n = extTrackRoot->GetTof2VolumeNumber() ;
105 double tof2= extTrackRoot->GetTof2();
106 double tof2path = extTrackRoot->GetTof2Path();
107 double z2 = extTrackRoot->GetTof2PosSigmaAlongZ() ;
108 double t2 = extTrackRoot->GetTof2PosSigmaAlongT();
109 double x2 = extTrackRoot->GetTof2PosSigmaAlongX();
110 double y2 = extTrackRoot->GetTof2PosSigmaAlongY();
111 HepSymMatrix e2m(6) ;
112 for (int i = 0;i<6 ;i++ )
113 for (int j= 0;j<6 ;j++ )
114 e2m[i][j]= extTrackRoot->GetTof2ErrorMatrix(i,j) ;
115
116 //Emc
117 double pEx = extTrackRoot->GetEmcPositionX();
118 double pEy = extTrackRoot->GetEmcPositionY();
119 double pEz = extTrackRoot->GetEmcPositionZ();
120 double mEx = extTrackRoot->GetEmcMomentumX();
121 double mEy = extTrackRoot->GetEmcMomentumY();
122 double mEz = extTrackRoot->GetEmcMomentumZ();
123 Hep3Vector Ep(pEx,pEy,pEz);
124 Hep3Vector Em(mEx,mEy,mEz);
125
126 string vEs = extTrackRoot->GetEmcVolumeName().Data();
127 int vEn = extTrackRoot->GetEmcVolumeNumber();
128 double theta = extTrackRoot->GetEmcPosSigmaAlongTheta();
129 double phi = extTrackRoot->GetEmcPosSigmaAlongPhi();
130 HepSymMatrix eEm(6) ;
131 for(int i=0;i<6 ;i++ )
132 for(int j= 0;j<6 ;j++ )
133 eEm[i][j]= extTrackRoot->GetEmcErrorMatrix(i,j);
134 double emcPath=extTrackRoot->emcPath();
135
136 //Muc
137 double pMx = extTrackRoot->GetMucPositionX() ;
138 double pMy = extTrackRoot->GetMucPositionY() ;
139 double pMz = extTrackRoot->GetMucPositionZ() ;
140 double mMx = extTrackRoot->GetMucMomentumX() ;
141 double mMy = extTrackRoot->GetMucMomentumY() ;
142 double mMz = extTrackRoot->GetMucMomentumZ();
143 Hep3Vector Mp(pMx,pMy,pMz);
144 Hep3Vector Mm(mMx,mMy,mMz);
145
146 string vMs = extTrackRoot->GetMucVolumeName().Data();
147 int vMn = extTrackRoot->GetMucVolumeNumber() ;
148
149 double zM = extTrackRoot->GetMucPosSigmaAlongZ() ;
150 double tM = extTrackRoot->GetMucPosSigmaAlongT();
151 double xM = extTrackRoot->GetMucPosSigmaAlongX();
152 double yM = extTrackRoot->GetMucPosSigmaAlongY();
153 HepSymMatrix eMm(6) ;
154 for (int i = 0;i<6 ;i++ )
155 for (int j= 0;j<6 ;j++ )
156 eMm[i][j]= extTrackRoot->GetMucErrorMatrix(i,j) ;
157
158 DstExtTrack *extTrackTds = new DstExtTrack();
159 m_common.m_rootExtTrackMap[extTrackRoot] = extTrackTds;
160
161 //ExtMucHitVec
162 /*int size = extTrackRoot->GetSize();
163 ExtMucHit aExtMucHit;
164 // Hep3Vector p(0,0,0);
165 // Hep3Vector m(0,0,0);
166 string vs;
167 int vn;
168 double z;
169 double t;
170 double x;
171 double y;
172 HepSymMatrix matrix(6);
173 for(int i =0;i<size;i++){
174 double px = extTrackRoot->GetPositionX(i) ;
175 double py = extTrackRoot->GetPositionY(i) ;
176 double pz = extTrackRoot->GetPositionZ(i) ;
177 Hep3Vector p(px,py,pz);
178 double mx = extTrackRoot->GetMomentumX(i) ;
179 double my = extTrackRoot->GetMomentumY(i) ;
180 double mz = extTrackRoot->GetMomentumZ(i);
181 Hep3Vector m(mx,my,mz);
182 vs = extTrackRoot->GetVolumeName(i).Data();
183 vn = extTrackRoot->GetVolumeNumber(i) ;
184 z = extTrackRoot->GetPosSigmaAlongZ(i) ;
185 t = extTrackRoot->GetPosSigmaAlongT(i);
186 x = extTrackRoot->GetPosSigmaAlongX(i);
187 y = extTrackRoot->GetPosSigmaAlongY(i);
188 std::vector<double> vecError = extTrackRoot->GetErrorMatrix(i);
189 for(int k =0;i<6;k++){
190 for(int j =0; j<6;j++){
191 matrix[k][j] = vecError[k*6+j];
192 }
193 }
194 aExtMucHit.SetExtMucHit(p,m,vs,vn,matrix,z,t,x,y);
195 extTrackTds->AddExtMucHit(aExtMucHit);
196 }*/
197
198 // DstExtTrack *extTrackTds = new DstExtTrack();
199 extTrackTds->SetTrackId(trackId);
200 extTrackTds->SetTof1Data( tof1p, tof1m, v1s, v1n , tof1, tof1path, e1m, z1, t1, x1, y1 );
201 extTrackTds->SetTof2Data( tof2p, tof2m, v2s, v2n , tof2, tof2path, e2m, z2, t2, x2, y2 );
202 extTrackTds->SetEmcData( Ep, Em, vEs, vEn , theta, phi , eEm);
203 extTrackTds->SetEmcPath(emcPath);
204 extTrackTds->SetMucData( Mp, Mm, vMs, vMn , eMm, zM, tM, xM, yM );
205
206 extTrackTdsCol->push_back(extTrackTds);
207
208
209 //delete extTrackTds; // wensp add 2005/12/31
210 // extTrackTds = NULL;
211 }
212 //m_extTrackCol->Delete(); // wensp add 2005/12/30
213 delete m_extTrackCol;
214 m_extTrackCol = 0;
215 return StatusCode::SUCCESS;
216}
217
218StatusCode ExtTrackCnv::DataObjectToTObject(DataObject* obj,RootAddress* rootaddr) {
219
220 MsgStream log(msgSvc(), "ExtTrackCnv");
221 log << MSG::DEBUG << "ExtTrackCnv::DataObjectToTObject" << endreq;
222 StatusCode sc=StatusCode::SUCCESS;
223
224 DstExtTrackCol * extTrackColTds=dynamic_cast<DstExtTrackCol *> (obj);
225 if (!extTrackColTds) {
226 log << MSG::ERROR << "Could not downcast to DstExtTrackCol" << endreq;
227 return StatusCode::FAILURE;
228 }
229
230 DataObject *evt;
231 m_eds->findObject(EventModel::Dst::Event,evt);
232 if (evt==NULL) {
233 log << MSG::ERROR << "Could not get ReconEvent in TDS " << endreq;
234 return StatusCode::FAILURE;
235 }
236
237 DstEvent * devtTds=dynamic_cast<DstEvent *> (evt);
238 if (!devtTds) {
239 log << MSG::ERROR << "ExtTrackCnv:Could not downcast to TDS Dst Event" << endreq;
240 }
241 IOpaqueAddress *addr;
242
243 m_cnvSvc->getDstCnv()->createRep(evt,addr);
245
246 const TObjArray *m_extTrackCol = recEvt->getExtTrackCol();
247
248 if (!m_extTrackCol) return sc;
249
250 recEvt->clearExtTrackCol(); //necessary in case there is I/O at the same time since array is static
251 DstExtTrackCol::const_iterator extTrackTds;
252
253 for (extTrackTds = extTrackColTds->begin(); extTrackTds != extTrackColTds->end(); extTrackTds++) {
254 //Get Data from TDS
255 Int_t trackId = (*extTrackTds)->GetTrackId();
256 //Tof layer1
257 Double_t p1x = (*extTrackTds)->tof1Position().x();
258 Double_t p1y = (*extTrackTds)->tof1Position().y();
259 Double_t p1z = (*extTrackTds)->tof1Position().z();
260 Double_t m1x = (*extTrackTds)->tof1Momentum().x();
261 Double_t m1y = (*extTrackTds)->tof1Momentum().y();
262 Double_t m1z = (*extTrackTds)->tof1Momentum().z();
263
264 TString v1s = (*extTrackTds)->tof1VolumeName() ;
265 Int_t v1n = (*extTrackTds)->tof1VolumeNumber() ;
266 Double_t tof1= (*extTrackTds)->tof1();
267 Double_t tof1p = (*extTrackTds)->tof1Path();
268 Double_t z1 = (*extTrackTds)->tof1PosSigmaAlongZ();
269 Double_t t1 = (*extTrackTds)->tof1PosSigmaAlongT();
270 Double_t x1 = (*extTrackTds)->tof1PosSigmaAlongX();
271 Double_t y1 = (*extTrackTds)->tof1PosSigmaAlongY();
272 Double_t e1m[6][6];
273 HepSymMatrix e1mTds = (*extTrackTds)->tof1ErrorMatrix();
274 for (int i = 0;i<6 ;i++ )
275 for (int j= 0;j<6 ;j++ )
276 e1m[i][j] = e1mTds[i][j];
277
278 //Tof llayer2
279 Double_t p2x = (*extTrackTds)->tof2Position().x();
280 Double_t p2y = (*extTrackTds)->tof2Position().y();
281 Double_t p2z = (*extTrackTds)->tof2Position().z();
282 Double_t m2x = (*extTrackTds)->tof2Momentum().x();
283 Double_t m2y = (*extTrackTds)->tof2Momentum().y();
284 Double_t m2z = (*extTrackTds)->tof2Momentum().z();
285
286 TString v2s = (*extTrackTds)->tof2VolumeName() ;
287 Int_t v2n = (*extTrackTds)->tof2VolumeNumber() ;
288 Double_t tof2= (*extTrackTds)->tof2();
289 Double_t tof2p = (*extTrackTds)->tof2Path();
290 Double_t z2 = (*extTrackTds)->tof2PosSigmaAlongZ();
291 Double_t t2 = (*extTrackTds)->tof2PosSigmaAlongT();
292 Double_t x2 = (*extTrackTds)->tof2PosSigmaAlongX();
293 Double_t y2 = (*extTrackTds)->tof2PosSigmaAlongY();
294 Double_t e2m[6][6];
295 HepSymMatrix e2mTds = (*extTrackTds)->tof2ErrorMatrix();
296 for (int i = 0;i<6 ;i++ )
297 for (int j= 0;j<6 ;j++ )
298 e2m[i][j] = e2mTds[i][j];
299 //Emc
300 Double_t pEx = (*extTrackTds)->emcPosition().x();
301 Double_t pEy = (*extTrackTds)->emcPosition().y();
302 Double_t pEz = (*extTrackTds)->emcPosition().z();
303 Double_t mEx = (*extTrackTds)->emcMomentum().x();
304 Double_t mEy = (*extTrackTds)->emcMomentum().y();
305 Double_t mEz = (*extTrackTds)->emcMomentum().z();
306
307 TString vEs = (*extTrackTds)->emcVolumeName() ;
308 Int_t vEn = (*extTrackTds)->emcVolumeNumber() ;
309
310 Double_t theta = (*extTrackTds)->emcPosSigmaAlongTheta();
311 Double_t phi = (*extTrackTds)->emcPosSigmaAlongPhi();
312
313 Double_t eEm[6][6];
314 HepSymMatrix eEmTds = (*extTrackTds)->emcErrorMatrix();
315 for (int i = 0;i<6 ;i++ )
316 for (int j= 0;j<6 ;j++ )
317 eEm[i][j] = eEmTds[i][j];
318 Double_t emcPath=(*extTrackTds)->emcPath();
319
320 //Muc
321 Double_t pMx = (*extTrackTds)->mucPosition().x();
322 Double_t pMy = (*extTrackTds)->mucPosition().y();
323 Double_t pMz = (*extTrackTds)->mucPosition().z();
324 Double_t mMx = (*extTrackTds)->mucMomentum().x();
325 Double_t mMy = (*extTrackTds)->mucMomentum().y();
326 Double_t mMz = (*extTrackTds)->mucMomentum().z();
327
328 TString vMs = (*extTrackTds)->mucVolumeName() ;
329 Int_t vMn = (*extTrackTds)->mucVolumeNumber() ;
330
331 Double_t zM = (*extTrackTds)->mucPosSigmaAlongZ();
332 Double_t tM = (*extTrackTds)->mucPosSigmaAlongT();
333 Double_t xM = (*extTrackTds)->mucPosSigmaAlongX();
334 Double_t yM = (*extTrackTds)->mucPosSigmaAlongY();
335
336 Double_t eMm[6][6];
337 HepSymMatrix eMmTds = (*extTrackTds)->mucErrorMatrix();
338 for (int i = 0;i<6 ;i++ )
339 for (int j= 0;j<6 ;j++ )
340 eMm[i][j]= eMmTds[i][j];
341
342 //ExtMucHitVec
343 /*ExtMucHitVec vecHit = (*extTrackTds)->GetExtMucHitVec();
344 Int_t size = vecHit.size();*/
345
346 TExtTrack *extTrackRoot = new TExtTrack();
347 //m_common.m_extTrackMap[(*extTrackTds)] = extTrackRoot;
348
349 //Set to Root
350
351 //ExtMucHitVec
352 /*extTrackRoot->SetSize(size);
353 for(int i=0;i<size;i++){
354 Double_t px = vecHit[i].GetPosition().x();
355 Double_t py = vecHit[i].GetPosition().y();
356 Double_t pz = vecHit[i].GetPosition().z();
357 Double_t mx = vecHit[i].GetMomentum().x();
358 Double_t my = vecHit[i].GetMomentum().y();
359 Double_t mz = vecHit[i].GetMomentum().z();
360 TString vs = vecHit[i].GetVolumeName();
361 Int_t vn = vecHit[i].GetVolumeNumber();
362 Double_t z = vecHit[i].GetPosSigmaAlongZ();
363 Double_t t = vecHit[i].GetPosSigmaAlongT();
364 Double_t x = vecHit[i].GetPosSigmaAlongX();
365 Double_t y = vecHit[i].GetPosSigmaAlongY();
366 Double_t m[6][6];
367 HepSymMatrix mTds = vecHit[i].GetErrorMatrix();
368 for (int j = 0;j<6;j++)
369 for(int k=0;k<6;k++)
370 m[i][j] = mTds[i][j];
371 extTrackRoot->SetExtMucHit(px,py,pz,mx,my,mz,vs,vn,z,t,y,x,m);
372 }*/
373
374 //Set to Root
375 extTrackRoot->SetTrackId(trackId);
376 //Tof layer1
377 extTrackRoot->SetTof1PositionX(p1x);
378 extTrackRoot->SetTof1PositionY(p1y);
379 extTrackRoot->SetTof1PositionZ(p1z);
380 extTrackRoot->SetTof1MomentumX(m1x);
381 extTrackRoot->SetTof1MomentumY(m1y);
382 extTrackRoot->SetTof1MomentumZ(m1z);
383
384 extTrackRoot->SetTof1VolumeName(v1s);
385 extTrackRoot->SetTof1VolumeNumber(v1n);
386
387 extTrackRoot->SetTof1(tof1);
388 extTrackRoot->SetTof1Path(tof1p);
389
390 extTrackRoot->SetTof1PosSigmaAlongZ(z1);
391 extTrackRoot->SetTof1PosSigmaAlongT(t1);
392 extTrackRoot->SetTof1PosSigmaAlongX(x1);
393 extTrackRoot->SetTof1PosSigmaAlongY(y1);
394
395 extTrackRoot->SetTof1ErrorMatrix(e1m);
396 //Tof layer2
397 extTrackRoot->SetTof2PositionX(p2x);
398 extTrackRoot->SetTof2PositionY(p2y);
399 extTrackRoot->SetTof2PositionZ(p2z);
400 extTrackRoot->SetTof2MomentumX(m2x);
401 extTrackRoot->SetTof2MomentumY(m2y);
402 extTrackRoot->SetTof2MomentumZ(m2z);
403
404 extTrackRoot->SetTof2VolumeName(v2s);
405 extTrackRoot->SetTof2VolumeNumber(v2n);
406
407 extTrackRoot->SetTof2(tof2);
408 extTrackRoot->SetTof2Path(tof2p);
409
410 extTrackRoot->SetTof2PosSigmaAlongZ(z2);
411 extTrackRoot->SetTof2PosSigmaAlongT(t2);
412 extTrackRoot->SetTof2PosSigmaAlongX(x2);
413 extTrackRoot->SetTof2PosSigmaAlongY(y2);
414
415 extTrackRoot->SetTof2ErrorMatrix(e2m);
416 //Emc
417 extTrackRoot->SetEmcPositionX(pEx);
418 extTrackRoot->SetEmcPositionY(pEy);
419 extTrackRoot->SetEmcPositionZ(pEz);
420 extTrackRoot->SetEmcMomentumX(mEx);
421 extTrackRoot->SetEmcMomentumY(mEy);
422 extTrackRoot->SetEmcMomentumZ(mEz);
423
424 extTrackRoot->SetEmcVolumeName(vEs);
425 extTrackRoot->SetEmcVolumeNumber(vEn);
426
427 extTrackRoot->SetEmcPosSigmaAlongTheta(theta);
428 extTrackRoot->SetEmcPosSigmaAlongPhi(phi);
429
430 extTrackRoot->SetEmcErrorMatrix(eEm);
431 extTrackRoot->SetEmcPath(emcPath);
432 //Muc
433 extTrackRoot->SetMucPositionX(pMx);
434 extTrackRoot->SetMucPositionY(pMy);
435 extTrackRoot->SetMucPositionZ(pMz);
436 extTrackRoot->SetMucMomentumX(mMx);
437 extTrackRoot->SetMucMomentumY(mMy);
438 extTrackRoot->SetMucMomentumZ(mMz);
439
440 extTrackRoot->SetMucVolumeName(vMs);
441 extTrackRoot->SetMucVolumeNumber(vMn);
442
443 extTrackRoot->SetMucPosSigmaAlongZ(zM);
444 extTrackRoot->SetMucPosSigmaAlongT(tM);
445 extTrackRoot->SetMucPosSigmaAlongX(xM);
446 extTrackRoot->SetMucPosSigmaAlongY(yM);
447
448 extTrackRoot->SetMucErrorMatrix(eMm);
449
450 recEvt->addExtTrack(extTrackRoot);
451 }
452
453 return StatusCode::SUCCESS;
454}
455#endif
ObjectVector< DstExtTrack > DstExtTrackCol
static TDstEvent * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
void SetTof1Data(Hep3Vector aPosition, Hep3Vector aMomentum, string aVolumeName, int aVolumeNumber, double aTof, double aPath, HepSymMatrix aErrorMatrix, double aZSigma=0., double aTSigma=0., double aXSigma=0., double aYSigma=0.)
void SetEmcData(Hep3Vector aPosition, Hep3Vector aMomentum, string aVolumeName, int aVolumeNumber, double aThetaSigma, double aPhiSigma, HepSymMatrix aErrorMatrix)
void SetTof2Data(Hep3Vector aPosition, Hep3Vector aMomentum, string aVolumeName, int aVolumeNumber, double aTof, double aPath, HepSymMatrix aErrorMatrix, double aZSigma=0., double aTSigma=0., double aXSigma=0., double aYSigma=0.)
void SetMucData(Hep3Vector aPosition, Hep3Vector aMomentum, string aVolumeName, int aVolumeNumber, HepSymMatrix aErrorMatrix, double aZSigma=0., double aTSigma=0., double aXSigma=0., double aYSigma=0.)
ExtTrackCnv(ISvcLocator *svc)
Definition: ExtTrackCnv.cxx:38
virtual StatusCode DataObjectToTObject(DataObject *obj, RootAddress *addr)
transformation to root
virtual StatusCode TObjectToDataObject(DataObject *&obj)
transformation from root
Definition: ExtTrackCnv.cxx:50
Definition of a Root address, derived from IOpaqueAddress.
IDataProviderSvc * m_eds
pointer to eventdataservice
std::vector< void * > m_adresses
each converter knows the corresponding adresses
std::string m_rootBranchname
root branchname (may be concatenated of severals)
virtual StatusCode createRep(DataObject *pObject, IOpaqueAddress *&refpAddress)
Convert the transient object to the requested representation.
void addExtTrack(TExtTrack *Track)
Add a ExtTrack into the Ext Data collection.
Definition: TDstEvent.cxx:175
const TObjArray * getExtTrackCol() const
retrieve the whole TObjArray of Ext Data
void SetTof1PosSigmaAlongZ(const Double_t Tof1PosSigmaAlongZ)
void SetTof1PosSigmaAlongX(const Double_t Tof1PosSigmaAlongX)
void SetTof1PosSigmaAlongY(const Double_t Tof1PosSigmaAlongY)
void SetEmcErrorMatrix(const Double_t EmcErrorMatrix[6][6])
void SetMucErrorMatrix(const Double_t MucErrorMatrix[6][6])
void SetTof1PosSigmaAlongT(const Double_t Tof1PosSigmaAlongT)
void SetMucPosSigmaAlongX(const Double_t MucPosSigmaAlongX)
void SetTof2PosSigmaAlongY(const Double_t Tof2PosSigmaAlongY)
void SetMucPosSigmaAlongY(const Double_t MucPosSigmaAlongY)
void SetTof2ErrorMatrix(const Double_t Tof2ErrorMatrix[6][6])
void SetTof2PosSigmaAlongZ(const Double_t Tof2PosSigmaAlongZ)
void SetMucPosSigmaAlongT(const Double_t MucPosSigmaAlongT)
void SetMucPosSigmaAlongZ(const Double_t MucPosSigmaAlongZ)
void SetTof2PosSigmaAlongX(const Double_t Tof2PosSigmaAlongX)
void SetTof2PosSigmaAlongT(const Double_t Tof2PosSigmaAlongT)
void SetTof1ErrorMatrix(const Double_t Tof1ErrorMatrix[6][6])
void SetEmcPosSigmaAlongTheta(const Double_t EmcPosSigmaAlongTheta)
void SetEmcPosSigmaAlongPhi(const Double_t EmcPosSigmaAlongPhi)
static std::map< const TObject *, const DstExtTrack * > m_rootExtTrackMap