ATLAS Offline Software
CMXRoICnv_p1.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2018 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 
7 
8 // Gaudi/Athena include(s):
9 #include "GaudiKernel/MsgStream.h"
10 
11 // Local include(s):
12 //#include "TrigT1EventTPCnv/CMXRoI_p1.h"
14 
15 using namespace LVL1;
16 
17 /*
18 CMXRoICnv_p1::CMXRoICnv_p1()
19  : T_AthenaPoolTPCnvBase< CMXRoI, CMXRoI_p1 >() {
20 
21 }
22 */
23 
24 void CMXRoICnv_p1::persToTrans( const CMXRoI_p1* persObj, CMXRoI* transObj, MsgStream &log ) {
25 
26  //log << MSG::INFO << "Converting CMXRoI from persistent state..." << endmsg;
27 
28  //transObj->clear(); // see if I actually need one of these
29 
30  //
31  // Translate the CMXRoI
32  //
33  *transObj = CMXRoI (persObj->m_roiWords[0],
34  persObj->m_roiWords[1],
35  persObj->m_roiWords[2],
36  persObj->m_roiWords[3],
37  persObj->m_roiWords[4],
38  persObj->m_roiWords[5]);
39 
40  if (log.level() <= MSG::DEBUG) log << MSG::DEBUG << "Converted CMXRoI from persistent state [OK]" << endmsg;
41 
42  return;
43 
44 }
45 
46 void CMXRoICnv_p1::transToPers( const CMXRoI* transObj, CMXRoI_p1* persObj, MsgStream &log ) {
47 
48  //log << MSG::INFO << "Creating persistent state of CMXRoI..." << endmsg;
49 
50  persObj->m_roiWords.resize(6);
51  for (int i=0; i < 6; i++)
52  persObj->m_roiWords[i] = transObj->roiWord(i);
53 
54  if (log.level() <= MSG::DEBUG) log << MSG::DEBUG << "Created persistent state of CMXRoI [OK]" << endmsg;
55 
56  return;
57 
58 }
LVL1::CMXRoI
CMX RoI data.
Definition: Trigger/TrigT1/TrigT1CaloEvent/TrigT1CaloEvent/CMXRoI.h:22
CMXRoI_p1::m_roiWords
std::vector< uint32_t > m_roiWords
Destructor.
Definition: CMXRoI_p1.h:26
LVL1
eFexTowerBuilder creates xAOD::eFexTowerContainer from supercells (LATOME) and triggerTowers (TREX) i...
Definition: ICMMCPHitsCnvTool.h:18
CMXRoICnv_p1::transToPers
virtual void transToPers(const LVL1::CMXRoI *transObj, CMXRoI_p1 *persObj, MsgStream &log)
Definition: CMXRoICnv_p1.cxx:46
CMXRoICnv_p1.h
lumiFormat.i
int i
Definition: lumiFormat.py:85
xAOD::CMXRoI
CMXRoI_v1 CMXRoI
Define the latest version of the CMXRoI class.
Definition: Event/xAOD/xAODTrigL1Calo/xAODTrigL1Calo/CMXRoI.h:14
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
CMXRoI_p1
T/P separation for TrigT1Calo::CMXRoI class.
Definition: CMXRoI_p1.h:12
CMXRoI.h
CMXRoICnv_p1::persToTrans
virtual void persToTrans(const CMXRoI_p1 *persObj, LVL1::CMXRoI *transObj, MsgStream &log)
Definition: CMXRoICnv_p1.cxx:24
DEBUG
#define DEBUG
Definition: page_access.h:11
python.CaloCondTools.log
log
Definition: CaloCondTools.py:20
LVL1::CMXRoI::roiWord
uint32_t roiWord(int word) const
Return packed Energy RoI word (0-5)
Definition: Trigger/TrigT1/TrigT1CaloEvent/TrigT1CaloEvent/CMXRoI.h:149