ATLAS Offline Software
TRT_DriftCircleCnv_p1.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 //-----------------------------------------------------------------------------
6 //
7 // file: TRT_DriftCircleCnv_p1.cxx
8 //
9 //-----------------------------------------------------------------------------
10 
13 
14 
16  InDet::TRT_DriftCircle *transObj,
17  MsgStream &log )
18 {
19  Amg::Vector2D localPos;
20  localPos.setZero();
21 
22  unsigned int trtdata = persObj->m_driftTimeValid ? 0x08000000 : 0x0;
23  if(persObj->m_highLevel)
24  trtdata |=0x04020100;
25 
26  *transObj = InDet::TRT_DriftCircle (Identifier(),
27  localPos,
28  std::vector<Identifier>(), // rdoList
29  {}, // cmat
30  nullptr, // detEl
31  trtdata
32  );
33 
34  fillTransFromPStore( &m_rawDataCnv, persObj->m_rawData, transObj, log );
35 }
36 
39  MsgStream &log)
40 {
41  persObj->m_rawData = baseToPersistent( &m_rawDataCnv, transObj, log );
42 
43  persObj->m_driftTimeValid = transObj->getWord() & 0x08000000;
44  persObj->m_highLevel = transObj->getWord() & 0x04020100;
45 }
46 
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
InDet::TRT_DriftCircle_p1::m_highLevel
bool m_highLevel
Definition: TRT_DriftCircle_p1.h:34
InDet::TRT_DriftCircle_p1::m_driftTimeValid
bool m_driftTimeValid
Definition: TRT_DriftCircle_p1.h:33
TRT_DriftCircleCnv_p1::m_rawDataCnv
ITPConverterFor< Trk::PrepRawData > * m_rawDataCnv
Definition: TRT_DriftCircleCnv_p1.h:37
InDet::TRT_DriftCircle
Definition: TRT_DriftCircle.h:32
ITPConverterFor< TRANS_BASE >::fillTransFromPStore
void fillTransFromPStore(CNV **cnv, const TPObjRef &ref, TRANS_T *trans, MsgStream &log) const
Convert persistent object, stored in the the top-level persistent object and referenced by the TP Ref...
Definition: TPConverter.h:145
Identifier
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:32
TRT_DriftCircle.h
ITPConverterFor< TRANS_BASE >::baseToPersistent
TPObjRef baseToPersistent(CNV **cnv, const typename CNV::Trans_t *transObj, MsgStream &log) const
Persistify bass class of a given object and store the persistent represenation in the storage vector ...
Definition: TPConverter.h:97
TRT_DriftCircleCnv_p1.h
TRT_DriftCircleCnv_p1::persToTrans
void persToTrans(const InDet::TRT_DriftCircle_p1 *persObj, InDet::TRT_DriftCircle *transObj, MsgStream &log)
Definition: TRT_DriftCircleCnv_p1.cxx:15
python.CaloCondTools.log
log
Definition: CaloCondTools.py:20
InDet::TRT_DriftCircle_p1
Definition: TRT_DriftCircle_p1.h:20
InDet::TRT_DriftCircle_p1::m_rawData
TPObjRef m_rawData
Definition: TRT_DriftCircle_p1.h:29
InDet::TRT_DriftCircle::getWord
unsigned int getWord() const
returns the TRT dataword
TRT_DriftCircleCnv_p1::transToPers
void transToPers(const InDet::TRT_DriftCircle *transObj, InDet::TRT_DriftCircle_p1 *persObj, MsgStream &log)
Definition: TRT_DriftCircleCnv_p1.cxx:37