#include <TofTrackCnv.h>
Inheritance diagram for TofTrackCnv:
Public Types | |
typedef Ty2 | destination |
typedef Ty2 | destination |
typedef Ty1 | source |
typedef Ty1 | source |
Public Member Functions | |
virtual StatusCode | createObj (IOpaqueAddress *addr, DataObject *&dat) |
Convert the persistent object to transient. | |
virtual StatusCode | createObj (IOpaqueAddress *addr, DataObject *&dat) |
Convert the persistent object to transient. | |
virtual StatusCode | createRep (DataObject *pObject, IOpaqueAddress *&refpAddress) |
Convert the transient object to the requested representation. | |
virtual StatusCode | createRep (DataObject *pObject, IOpaqueAddress *&refpAddress) |
Convert the transient object to the requested representation. | |
void | declareObject (const std::string &fullPath, const CLID &clid, const std::string &treename, const std::string &branchname) |
Store TDS path to link a particular converter to an object on the TDS. | |
void | declareObject (const std::string &fullPath, const CLID &clid, const std::string &treename, const std::string &branchname) |
Store TDS path to link a particular converter to an object on the TDS. | |
virtual StatusCode | fillObjRefs (IOpaqueAddress *pAddress, DataObject *pObject) |
Resolve the references of the converted object. | |
virtual StatusCode | fillObjRefs (IOpaqueAddress *pAddress, DataObject *pObject) |
Resolve the references of the converted object. | |
virtual StatusCode | fillRepRefs (IOpaqueAddress *pAddress, DataObject *pObject) |
Resolve the references of the converted object. | |
virtual StatusCode | fillRepRefs (IOpaqueAddress *pAddress, DataObject *pObject) |
Resolve the references of the converted object. | |
virtual StatusCode | finalize () |
virtual StatusCode | finalize () |
TObject * | getReadObject () const |
get the object to be read | |
TObject * | getReadObject () const |
get the object to be read | |
virtual StatusCode | initialize () |
virtual StatusCode | initialize () |
destination * | operator (const source &) const |
destination * | operator (const source &) const |
virtual long | repSvcType () const |
virtual long | repSvcType () const |
virtual | ~TofTrackCnv () |
virtual | ~TofTrackCnv () |
Static Public Member Functions | |
const CLID & | classID () |
const CLID & | classID () |
const unsigned char | storageType () |
Storage type and class ID. | |
const unsigned char | storageType () |
Storage type and class ID. | |
Protected Member Functions | |
virtual destination * | convert (const source &) const =0 |
virtual destination * | convert (const source &) const =0 |
virtual StatusCode | DataObjectToTObject (DataObject *obj, RootAddress *addr) |
transformation to root | |
virtual StatusCode | DataObjectToTObject (DataObject *obj, RootAddress *addr) |
transformation to root | |
virtual StatusCode | TObjectToDataObject (DataObject *&obj) |
transformation from root | |
virtual StatusCode | TObjectToDataObject (DataObject *&obj) |
transformation from root | |
TofTrackCnv (ISvcLocator *svc) | |
TofTrackCnv (ISvcLocator *svc) | |
Protected Attributes | |
CLID | CLID_top |
the CLID of the upper converter if any | |
std::vector< void * > | m_adresses |
each converter knows the corresponding adresses | |
std::vector< void * > | m_adresses |
each converter knows the corresponding adresses | |
int | m_branchNr |
the branchNr of this converter for writing | |
int | m_branchNrDst |
int | m_branchNrEvtHeader |
int | m_branchNrEvtRec |
int | m_branchNrMc |
int | m_branchNrRecon |
TArrayS * | m_branchNumbers |
array with number of branches for reading | |
TArrayS * | m_branchNumbers |
array with number of branches for reading | |
RootCnvSvc * | m_cnvSvc |
RootCnvSvc * | m_cnvSvc |
std::string | m_currentFileName |
IDataProviderSvc * | m_eds |
pointer to eventdataservice | |
IDataProviderSvc * | m_eds |
pointer to eventdataservice | |
RootEvtSelector * | m_evtsel |
RootEvtSelector * | m_evtsel |
std::vector< RootCnvSvc::Leaf > | m_leaves |
std::vector< RootCnvSvc::Leaf > | m_leaves |
TObject * | m_objRead |
the object that was read | |
TObject * | m_objRead |
the object that was read | |
std::string | m_rootBranchname |
root branchname (may be concatenated of severals) | |
RootInterface * | m_rootInterface |
pointer to the RootInterface | |
RootInterface * | m_rootInterface |
pointer to the RootInterface | |
std::string | m_rootTreename |
each converter knows it's treename | |
Private Attributes | |
commonData | m_common |
relational maps | |
TObjArray * | m_tofTrackCol |
root object to be read | |
TObjArray * | m_tofTrackCol |
root object to be read | |
Friends | |
class | CnvFactory<TofTrackCnv> |
|
|
|
|
|
|
|
|
|
00025 { };
|
|
00031 : RootEventBaseCnv(classID(), svc) 00032 { 00033 // Here we associate this converter with the /Event path on the TDS. 00034 MsgStream log(msgSvc(), "TofTrackCnv"); 00035 //log << MSG::DEBUG << "Constructor called for " << objType() << endreq; 00036 m_rootBranchname ="m_tofTrackCol"; 00037 //declareObject(EventModel::Dst::DstTofTrackCol, objType(), m_rootTreename, m_rootBranchname); 00038 m_adresses.push_back(&m_tofTrackCol); 00039 m_tofTrackCol=0; 00040 }
|
|
00025 { };
|
|
|
|
00021 {
00022 return CLID_DstTofTrackCol;
00023 }
|
|
00021 {
00022 return CLID_DstTofTrackCol;
00023 }
|
|
|
|
|
|
Convert the persistent object to transient.
|
|
Convert the persistent object to transient.
Reimplemented in EventCnv, and EventCnv. 00157 { 00158 // transform ROOT object to TDS object 00159 MsgStream log(msgSvc(), "RootEventBaseCnv"); 00160 log << MSG::DEBUG << "RootEventBaseCnv::createObj with clid " <<addr->clID()<< endreq; 00161 StatusCode sc; 00162 00163 // add 2005-11-29 00164 // log<<MSG::INFO<<"######### RootEventBaseCnv ::createObj begin of createObj: m_branchNumbers "<<m_branchNumbers->GetSize()<<"###############"<<endreq; 00165 00166 RootAddress *raddr=dynamic_cast<RootAddress *>(addr); 00167 if (!raddr) { 00168 log << MSG::ERROR << "Could not downcast to Root address" << endreq; 00169 return StatusCode::FAILURE; 00170 } 00171 00172 static int temp =0; //control the begin of each files 2005-12-01 00173 static int entryN =0; //control the event number of each files 2005-21-01 00174 static int brN =0; //control munber of branch of the tree; 00175 int lastBrn = brN; 00176 //lastBrn = brN; 00177 static int branchN=0; 00178 static bool isSet=true; 00179 00180 static int entryBefore = 0; 00181 static bool addEntryEachFile = true; 00182 00183 00184 if(m_rootInterface->getENDFILE() || (temp >0 && temp < branchN)){ // if the file has get the end:y the go to next file to create a new tree 00185 00186 if(m_rootInterface->getENDFILE() ) { 00187 entryN = 0; 00188 } 00189 00190 temp++; 00191 00192 delete m_branchNumbers; 00193 m_branchNumbers = new TArrayS(0); 00194 00195 if(temp == branchN) { 00196 temp =0; 00197 } 00198 } 00199 00200 if(m_rootInterface->getENDFILE()) addEntryEachFile = true; 00201 // the 2nd method 00202 if(m_evtsel->getRecId() - entryBefore == 0) { // first event in this file 00203 delete m_branchNumbers; 00204 m_branchNumbers = new TArrayS(0); 00205 } 00206 00207 //new method to initialize the branchNumber 00208 if(m_currentFileName=="") m_currentFileName = m_rootInterface->getCurrentFileName(); 00209 if(!(m_currentFileName == m_rootInterface->getCurrentFileName())){ 00210 m_currentFileName = m_rootInterface->getCurrentFileName(); 00211 delete m_branchNumbers; 00212 m_branchNumbers = new TArrayS(0); 00213 } 00214 //---------------------------------------- 00215 00216 00217 if (m_branchNumbers->GetSize()<=0) { 00218 if(isSet) brN++; 00219 int branchNumber; 00220 for (int nb=0;nb<raddr->getNrBranches();nb++) { 00221 sc=m_rootInterface->setBranchAddress(raddr->getTreename().c_str(),raddr->getBranchname(nb).c_str(),m_adresses[nb],branchNumber); 00222 if (!sc.isSuccess()) 00223 { 00224 if(isSet) brN--; //liangyt: if fail to retrieve this branch, this will be not a effective branch. 00225 //entryN++; //liangyt: this is the second method 00226 if(temp>0) temp--; //temp > 0 means recording effective branch number. 00227 return sc; 00228 } 00229 m_branchNumbers->Set(nb+1); 00230 m_branchNumbers->AddAt(branchNumber,nb); 00231 00232 } 00233 } 00234 00236 if(addEntryEachFile&&(m_evtsel->getRecId()>entryBefore)){ // for a new file, add entry for ONLY one time. 00237 entryBefore += m_rootInterface->getEntries(); 00238 addEntryEachFile = false; 00239 } 00240 00241 if(lastBrn == brN && isSet ){ 00242 branchN = brN; 00243 isSet=false; 00244 } 00245 00246 if(isSet==false) log << MSG::INFO <<" 1st method set event as : "<<int(entryN/branchN)<<endreq; 00247 if(isSet==false) raddr->setEntryNr(int(entryN/branchN));//former method, keep it to be backup. 00248 if(m_evtsel) log << MSG::INFO <<" event id = "<<m_evtsel->getRecId()<<endreq; 00249 00250 int eventID = 0; 00251 if(entryBefore > m_evtsel->getRecId()) 00252 eventID = m_evtsel->getRecId() + m_rootInterface->getEntries() - entryBefore; 00253 else if(entryBefore == m_evtsel->getRecId()) eventID = 0; 00254 else log << MSG::ERROR <<"eventId error!!!"<<endreq; 00255 00256 log << MSG::INFO <<" 2nd method set event as : "<<eventID<<endreq; 00257 if(m_evtsel) raddr->setEntryNr(eventID); 00258 // read branch 00259 00260 if (m_branchNumbers->GetSize()>0) { 00261 int nbtot=0,nb; 00262 for (int ib=0;ib<m_branchNumbers->GetSize();ib++) { 00263 //sc=m_rootInterface->getBranchEntry(m_branchNumbers->At(ib),raddr->getEntryNr(),nb); 00264 //change to get branch entry with addr(set address for each entry) liangyt 00265 sc=m_rootInterface->getBranchEntry(m_branchNumbers->At(ib),raddr->getEntryNr(),m_adresses[ib],nb); 00266 if (sc.isFailure()) { 00267 log << MSG::ERROR << "Could not read branch " << raddr->getBranchname(nb) << endreq; 00268 return sc; 00269 } 00270 nbtot+=nb; 00271 } 00272 } 00273 00274 else { // get ROOT object 00275 if (CLID_top) { 00276 IConverter *p=conversionSvc()->converter(CLID_top); 00277 RootEventBaseCnv *cnv=dynamic_cast<RootEventBaseCnv *>(p); 00278 if (!cnv) { 00279 log << MSG::ERROR << "Could not downcast to RootEventBaseCnv " << endreq; 00280 return StatusCode::FAILURE; 00281 } 00282 m_objRead=cnv->getReadObject(); 00283 } 00284 } 00285 00286 //do concrete transformation in derived converter 00287 sc = TObjectToDataObject(refpObject); 00288 if (sc.isFailure()) { 00289 log << MSG::ERROR << "Could not transform object" << endreq; 00290 return sc; 00291 } 00292 00293 // verify if we have to register 00294 IRegistry* ent = addr->registry(); 00295 if ( ent == 0) { 00296 sc=m_eds->registerObject(raddr->getPath(),refpObject); 00297 if (sc.isFailure()) { 00298 log << MSG::ERROR << "Could not register object " << raddr->getPath()<<" status "<<sc.getCode()<<endreq; 00299 } 00300 // } 00301 } 00302 00303 entryN++; 00304 return StatusCode::SUCCESS; 00305 }
|
|
Convert the transient object to the requested representation.
|
|
Convert the transient object to the requested representation.
00078 { 00079 // Purpose and Method: Convert the transient object to ROOT 00080 00081 MsgStream log(msgSvc(), "RootEventBaseCnv"); 00082 00083 StatusCode sc= StatusCode::SUCCESS; 00084 // get the corresponding address 00085 RootAddress *rootaddr; 00086 sc=m_cnvSvc->createAddress(obj,addr); 00087 00088 rootaddr = dynamic_cast<RootAddress *>(addr); 00089 00090 if (sc.isFailure() || !rootaddr ) { 00091 log << MSG::ERROR << "Could not create address for clid " <<obj->clID()<<", objname "<<obj->name()<<endreq; 00092 return StatusCode::FAILURE; 00093 } 00094 00095 // do the real conversion in the derived converter 00096 sc = DataObjectToTObject(obj,rootaddr); 00097 00098 delete addr; 00099 addr = NULL; 00100 00101 if (sc.isFailure()) { 00102 log << MSG::ERROR << "Could not transform object" << endreq; 00103 return sc; 00104 } 00105 00106 return StatusCode::SUCCESS; 00107 }
|
|
transformation to root
Implements RootEventBaseCnv. |
|
transformation to root
Implements RootEventBaseCnv. 00146 { 00147 00148 MsgStream log(msgSvc(), "TofTrackCnv"); 00149 log << MSG::DEBUG << "TofTrackCnv::DataObjectToTObject" << endreq; 00150 StatusCode sc=StatusCode::SUCCESS; 00151 00152 DstTofTrackCol * tofTrackColTds=dynamic_cast<DstTofTrackCol *> (obj); 00153 if (!tofTrackColTds) { 00154 log << MSG::ERROR << "Could not downcast to DstTofTrackCol" << endreq; 00155 return StatusCode::FAILURE; 00156 } 00157 00158 DataObject *evt; 00159 m_eds->findObject(EventModel::Dst::Event,evt); 00160 if (evt==NULL) { 00161 log << MSG::ERROR << "Could not get DstEvent in TDS " << endreq; 00162 return StatusCode::FAILURE; 00163 } 00164 00165 DstEvent * devtTds=dynamic_cast<DstEvent *> (evt); 00166 if (!devtTds) { 00167 log << MSG::ERROR << "TofTrackCnv:Could not downcast to TDS ReconEvent" << endreq; 00168 } 00169 IOpaqueAddress *addr; 00170 00171 m_cnvSvc->getDstCnv()->createRep(evt,addr); 00172 TDstEvent *recEvt=m_cnvSvc->getDstCnv()->getWriteObject(); 00173 00174 const TObjArray *m_tofTrackCol = recEvt->getTofTrackCol(); 00175 if (!m_tofTrackCol) return sc; 00176 recEvt->clearTofTrackCol(); //necessary in case there is I/O at the same time since array is static 00177 DstTofTrackCol::const_iterator tofTrackTds; 00178 00179 for (tofTrackTds = tofTrackColTds->begin(); tofTrackTds != tofTrackColTds->end(); tofTrackTds++) { 00180 00181 Int_t tofTrackID = (*tofTrackTds)->tofTrackID(); 00182 Int_t trackID = (*tofTrackTds)->trackID(); 00183 Int_t tofID = (*tofTrackTds)->tofID(); 00184 UInt_t status = (*tofTrackTds)->status(); 00185 Double_t path = (*tofTrackTds)->path(); 00186 Double_t zrhit = (*tofTrackTds)->zrhit(); 00187 Double_t ph = (*tofTrackTds)->ph(); 00188 Double_t tof = (*tofTrackTds)->tof(); 00189 Double_t errtof = (*tofTrackTds)->errtof(); 00190 Double_t beta = (*tofTrackTds)->beta(); 00191 Double_t texpElectron = (*tofTrackTds)->texpElectron(); 00192 Double_t texpMuon = (*tofTrackTds)->texpMuon(); 00193 Double_t texpPion = (*tofTrackTds)->texpPion(); 00194 Double_t texpKaon = (*tofTrackTds)->texpKaon(); 00195 Double_t texpProton = (*tofTrackTds)->texpProton(); 00196 Double_t toffsetElectron = (*tofTrackTds)->toffsetElectron(); 00197 Double_t toffsetMuon = (*tofTrackTds)->toffsetMuon(); 00198 Double_t toffsetPion = (*tofTrackTds)->toffsetPion(); 00199 Double_t toffsetKaon = (*tofTrackTds)->toffsetKaon(); 00200 Double_t toffsetProton = (*tofTrackTds)->toffsetProton(); 00201 Double_t toffsetAntiProton = (*tofTrackTds)->toffsetAntiProton(); 00202 Double_t sigmaElectron = (*tofTrackTds)->sigmaElectron(); 00203 Double_t sigmaMuon = (*tofTrackTds)->sigmaMuon(); 00204 Double_t sigmaPion = (*tofTrackTds)->sigmaPion(); 00205 Double_t sigmaKaon = (*tofTrackTds)->sigmaKaon(); 00206 Double_t sigmaProton = (*tofTrackTds)->sigmaProton(); 00207 Double_t sigmaAntiProton = (*tofTrackTds)->sigmaAntiProton(); 00208 Int_t quality = (*tofTrackTds)->quality(); 00209 Double_t t0 = (*tofTrackTds)->t0(); 00210 Double_t errt0 = (*tofTrackTds)->errt0(); 00211 Double_t errz = (*tofTrackTds)->errz(); 00212 Double_t phi = (*tofTrackTds)->phi(); 00213 Double_t errphi = (*tofTrackTds)->errphi(); 00214 Double_t energy = (*tofTrackTds)->energy(); 00215 Double_t errenergy = (*tofTrackTds)->errenergy(); 00216 00217 TTofTrack *tofTrackRoot = new TTofTrack(); 00218 00219 //m_common.m_tofTrackMap[(*tofTrackTds)] = tofTrackRoot; 00220 00221 tofTrackRoot->setTofTrackID(tofTrackID); 00222 tofTrackRoot->setTrackID(trackID); 00223 tofTrackRoot->setTofID(tofID); 00224 tofTrackRoot->setStatus(status); 00225 tofTrackRoot->setPath(path); 00226 tofTrackRoot->setZrHit(zrhit); 00227 tofTrackRoot->setPh(ph); 00228 tofTrackRoot->setTof(tof); 00229 tofTrackRoot->setErrTof(errtof); 00230 tofTrackRoot->setBeta(beta); 00231 tofTrackRoot->setTexpElectron(texpElectron); 00232 tofTrackRoot->setTexpMuon(texpMuon); 00233 tofTrackRoot->setTexpPion(texpPion); 00234 tofTrackRoot->setTexpKaon(texpKaon); 00235 tofTrackRoot->setTexpProton(texpProton); 00236 tofTrackRoot->setToffsetElectron(toffsetElectron); 00237 tofTrackRoot->setToffsetMuon(toffsetMuon); 00238 tofTrackRoot->setToffsetPion(toffsetPion); 00239 tofTrackRoot->setToffsetKaon(toffsetKaon); 00240 tofTrackRoot->setToffsetProton(toffsetProton); 00241 tofTrackRoot->setToffsetAntiProton(toffsetAntiProton); 00242 tofTrackRoot->setSigmaElectron(sigmaElectron); 00243 tofTrackRoot->setSigmaMuon(sigmaMuon); 00244 tofTrackRoot->setSigmaPion(sigmaPion); 00245 tofTrackRoot->setSigmaKaon(sigmaKaon); 00246 tofTrackRoot->setSigmaProton(sigmaProton); 00247 tofTrackRoot->setSigmaAntiProton(sigmaAntiProton); 00248 tofTrackRoot->setQuality(quality); 00249 tofTrackRoot->setT0(t0); 00250 tofTrackRoot->setErrT0(errt0); 00251 tofTrackRoot->setErrZ(errz); 00252 tofTrackRoot->setPhi(phi); 00253 tofTrackRoot->setErrPhi(errphi); 00254 tofTrackRoot->setEnergy(energy); 00255 tofTrackRoot->setErrEnergy(errenergy); 00256 00257 recEvt->addTofTrack(tofTrackRoot); 00258 } 00259 00260 return StatusCode::SUCCESS; 00261 }
|
|
Store TDS path to link a particular converter to an object on the TDS.
|
|
Store TDS path to link a particular converter to an object on the TDS.
00150 { 00151 // Purpose and Method: Save the path on the TDS, treename, pathname in the m_leaves vector, 00152 // corresponding to the DataObject that the converter handles. 00153 m_leaves.push_back(RootCnvSvc::Leaf(path, cl,treename,branchname)); 00154 }
|
|
Resolve the references of the converted object.
|
|
Resolve the references of the converted object.
00117 { 00118 // Purpose and Method: Resolve the references of the converted object. 00119 // It is expected that derived classes will override this method. 00120 MsgStream log(msgSvc(), "RootEventBaseCnv"); 00121 return StatusCode::SUCCESS; 00122 }
|
|
Resolve the references of the converted object.
|
|
Resolve the references of the converted object.
00109 { 00110 // Purpose and Method: Resolve the references of the converted object. 00111 // It is expected that derived classes will override this method. 00112 MsgStream log(msgSvc(), "RootEventBaseCnv"); 00113 return StatusCode::SUCCESS; 00114 }
|
|
|
|
00141 { 00142 if ( m_cnvSvc ) { 00143 m_cnvSvc->release(); 00144 m_cnvSvc=0; 00145 } 00146 return Converter::finalize(); 00147 }
|
|
get the object to be read
00124 { return m_objRead;}
|
|
get the object to be read
00124 { return m_objRead;}
|
|
Reimplemented in DigiCnv, DstCnv, EvtHeaderCnv, EvtRecCnv, HltCnv, McCnv, RecTrackCnv, TrigCnv, DigiCnv, DstCnv, EvtHeaderCnv, EvtRecCnv, HltCnv, McCnv, RecTrackCnv, and TrigCnv. |
|
Reimplemented in DigiCnv, DstCnv, EvtHeaderCnv, EvtRecCnv, HltCnv, McCnv, RecTrackCnv, TrigCnv, DigiCnv, DstCnv, EvtHeaderCnv, EvtRecCnv, HltCnv, McCnv, RecTrackCnv, and TrigCnv. 00125 { 00126 00127 StatusCode status = Converter::initialize(); 00128 00129 if ( status.isSuccess() ) { 00130 IService* isvc = 0; 00131 status = serviceLocator()->service("RootCnvSvc", isvc, false); 00132 if ( !status.isSuccess() ) status = serviceLocator()->service("EventCnvSvc", isvc, true); 00133 if ( status.isSuccess() ) { 00134 status = isvc->queryInterface(IID_IRootCnvSvc, (void**)&m_cnvSvc); 00135 } 00136 } 00137 00138 return status; 00139 }
|
|
|
|
|
|
00087 {
00088 return ROOT_StorageType;
00089 }
|
|
00087 {
00088 return ROOT_StorageType;
00089 }
|
|
Storage type and class ID.
00083 {
00084 return ROOT_StorageType;
00085 }
|
|
Storage type and class ID.
00083 {
00084 return ROOT_StorageType;
00085 }
|
|
transformation from root
Implements RootEventBaseCnv. |
|
transformation from root
Implements RootEventBaseCnv. 00042 { 00043 // creation of TDS object from root object 00044 00045 MsgStream log(msgSvc(), "TofTrackCnv"); 00046 log << MSG::DEBUG << "TofTrackCnv::TObjectToDataObject" << endreq; 00047 StatusCode sc=StatusCode::SUCCESS; 00048 // create the TDS location for the TofTrack Collection 00049 DstTofTrackCol* tofTrackTdsCol = new DstTofTrackCol; 00050 refpObject=tofTrackTdsCol; 00051 00052 00053 // now convert 00054 if (!m_tofTrackCol) return sc; 00055 TIter tofTrackIter(m_tofTrackCol); 00056 TTofTrack *tofTrackRoot = 0; 00057 while ((tofTrackRoot = (TTofTrack*)tofTrackIter.Next())) { 00058 00059 int tofTrackID = tofTrackRoot->tofTrackID(); 00060 int trackID = tofTrackRoot->trackID(); 00061 int tofID = tofTrackRoot->tofID(); 00062 unsigned int status = tofTrackRoot->status(); 00063 double path = tofTrackRoot->path(); 00064 double zrhit = tofTrackRoot->zrhit(); 00065 double ph = tofTrackRoot->ph(); 00066 double tof = tofTrackRoot->tof(); 00067 double errtof = tofTrackRoot->errtof(); 00068 double beta = tofTrackRoot->beta(); 00069 double texpElectron = tofTrackRoot->texpElectron(); 00070 double texpMuon = tofTrackRoot->texpMuon(); 00071 double texpPion = tofTrackRoot->texpPion(); 00072 double texpKaon = tofTrackRoot->texpKaon(); 00073 double texpProton = tofTrackRoot->texpProton(); 00074 double toffsetElectron = tofTrackRoot->toffsetElectron(); 00075 double toffsetMuon = tofTrackRoot->toffsetMuon(); 00076 double toffsetPion = tofTrackRoot->toffsetPion(); 00077 double toffsetKaon = tofTrackRoot->toffsetKaon(); 00078 double toffsetProton = tofTrackRoot->toffsetProton(); 00079 double toffsetAntiProton = tofTrackRoot->toffsetAntiProton(); 00080 double sigmaElectron = tofTrackRoot->sigmaElectron(); 00081 double sigmaMuon = tofTrackRoot->sigmaMuon(); 00082 double sigmaPion = tofTrackRoot->sigmaPion(); 00083 double sigmaKaon = tofTrackRoot->sigmaKaon(); 00084 double sigmaProton = tofTrackRoot->sigmaProton(); 00085 double sigmaAntiProton = tofTrackRoot->sigmaAntiProton(); 00086 int quality = tofTrackRoot->quality(); 00087 double t0 = tofTrackRoot->t0(); 00088 double errt0 = tofTrackRoot->errt0(); 00089 double errz = tofTrackRoot->errz(); 00090 double phi = tofTrackRoot->phi(); 00091 double errphi = tofTrackRoot->errphi(); 00092 double energy = tofTrackRoot->energy(); 00093 double errenergy = tofTrackRoot->errenergy(); 00094 00095 DstTofTrack *tofTrackTds = new DstTofTrack(); 00096 m_common.m_rootTofTrackMap[tofTrackRoot] = tofTrackTds; 00097 00098 tofTrackTds->setTofTrackID(tofTrackID); 00099 tofTrackTds->setTrackID(trackID); 00100 tofTrackTds->setTofID(tofID); 00101 tofTrackTds->setStatus(status); 00102 tofTrackTds->setPath(path); 00103 tofTrackTds->setZrHit(zrhit); 00104 tofTrackTds->setPh(ph); 00105 tofTrackTds->setTof(tof); 00106 tofTrackTds->setErrTof(errtof); 00107 tofTrackTds->setBeta(beta); 00108 tofTrackTds->setTexpElectron(texpElectron); 00109 tofTrackTds->setTexpMuon(texpMuon); 00110 tofTrackTds->setTexpPion(texpPion); 00111 tofTrackTds->setTexpKaon(texpKaon); 00112 tofTrackTds->setTexpProton(texpProton); 00113 tofTrackTds->setToffsetElectron(toffsetElectron); 00114 tofTrackTds->setToffsetMuon(toffsetMuon); 00115 tofTrackTds->setToffsetPion(toffsetPion); 00116 tofTrackTds->setToffsetKaon(toffsetKaon); 00117 tofTrackTds->setToffsetProton(toffsetProton); 00118 tofTrackTds->setToffsetAntiProton(toffsetAntiProton); 00119 tofTrackTds->setSigmaElectron(sigmaElectron); 00120 tofTrackTds->setSigmaMuon(sigmaMuon); 00121 tofTrackTds->setSigmaPion(sigmaPion); 00122 tofTrackTds->setSigmaKaon(sigmaKaon); 00123 tofTrackTds->setSigmaProton(sigmaProton); 00124 tofTrackTds->setSigmaAntiProton(sigmaAntiProton); 00125 tofTrackTds->setQuality(quality); 00126 tofTrackTds->setT0(t0); 00127 tofTrackTds->setErrT0(errt0); 00128 tofTrackTds->setErrZ(errz); 00129 tofTrackTds->setPhi(phi); 00130 tofTrackTds->setErrPhi(errphi); 00131 tofTrackTds->setEnergy(energy); 00132 tofTrackTds->setErrEnergy(errenergy); 00133 00134 tofTrackTdsCol->push_back(tofTrackTds); 00135 00136 // delete tofTrackTds; // wensp add 2005/12/31 00137 // tofTrackTds = NULL; 00138 } 00139 00140 //m_tofTrackCol->Delete(); // wensp add 2005/12/30 00141 delete m_tofTrackCol; 00142 m_tofTrackCol = 0; 00143 return StatusCode::SUCCESS; 00144 }
|
|
|
|
the CLID of the upper converter if any
|
|
each converter knows the corresponding adresses
|
|
each converter knows the corresponding adresses
|
|
the branchNr of this converter for writing
|
|
|
|
|
|
|
|
|
|
|
|
array with number of branches for reading
|
|
array with number of branches for reading
|
|
|
|
|
|
relational maps
|
|
|
|
pointer to eventdataservice
|
|
pointer to eventdataservice
|
|
|
|
|
|
|
|
|
|
the object that was read
|
|
the object that was read
|
|
root branchname (may be concatenated of severals)
|
|
pointer to the RootInterface
|
|
pointer to the RootInterface
|
|
each converter knows it's treename
|
|
root object to be read
|
|
root object to be read
|