ATLAS Offline Software
JEMHitsCnv_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/JEMHits_p1.h"
14 
15 using namespace LVL1;
16 
17 /*
18 JEMHitsCnv_p1::JEMHitsCnv_p1()
19  : T_AthenaPoolTPCnvBase< JEMHits, JEMHits_p1 >() {
20 
21 }
22 */
23 
24 void JEMHitsCnv_p1::persToTrans( const JEMHits_p1* persObj, JEMHits* transObj, MsgStream &log ) {
25 
26  //log << MSG::INFO << "Converting JEMHits from persistent state..." << endmsg;
27 
28  //transObj->clear(); // see if I actually need one of these
29 
30  //
31  // Translate the JEMHits
32  //
33  *transObj = JEMHits (persObj->m_crate,
34  persObj->m_module,
35  persObj->m_JetHits,
36  persObj->m_peak);
37 
38  if (log.level() <= MSG::DEBUG) log << MSG::DEBUG << "Converted JEMHits from persistent state [OK]" << endmsg;
39 
40  return;
41 
42 }
43 
44 void JEMHitsCnv_p1::transToPers( const JEMHits* transObj, JEMHits_p1* persObj, MsgStream &log ) {
45 
46  //log << MSG::INFO << "Creating persistent state of JEMHits..." << endmsg;
47 
48  persObj->m_crate = transObj->crate();
49  persObj->m_module = transObj->module();
50  persObj->m_peak = transObj->peak();
51  persObj->m_JetHits = transObj->JetHitsVec();
52 
53  if (log.level() <= MSG::DEBUG) log << MSG::DEBUG << "Created persistent state of JEMHits [OK]" << endmsg;
54 
55  return;
56 
57 }
LVL1::JEMHits::crate
int crate() const
returns crate number
Definition: JEMHits.cxx:60
xAOD::JEMHits
JEMHits_v1 JEMHits
Define the latest version of the JEMHits class.
Definition: Event/xAOD/xAODTrigL1Calo/xAODTrigL1Calo/JEMHits.h:14
JEMHits_p1::m_crate
int m_crate
Destructor.
Definition: JEMHits_p1.h:33
JEMHits_p1::m_JetHits
std::vector< unsigned int > m_JetHits
Definition: JEMHits_p1.h:36
JEMHitsCnv_p1.h
JEMHits_p1
T/P separation for TrigT1Calo::JEMHits class.
Definition: JEMHits_p1.h:19
LVL1
eFexTowerBuilder creates xAOD::eFexTowerContainer from supercells (LATOME) and triggerTowers (TREX) i...
Definition: ICMMCPHitsCnvTool.h:18
JEMHits_p1::m_peak
int m_peak
Definition: JEMHits_p1.h:35
JEMHits_p1::m_module
int m_module
Definition: JEMHits_p1.h:34
LVL1::JEMHits::JetHitsVec
const std::vector< unsigned int > & JetHitsVec() const
returns jet hits
Definition: JEMHits.cxx:75
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
LVL1::JEMHits::peak
int peak() const
returns peak slice number
Definition: JEMHits.cxx:95
LVL1::JEMHits::module
int module() const
returns module number
Definition: JEMHits.cxx:65
JEMHitsCnv_p1::persToTrans
virtual void persToTrans(const JEMHits_p1 *persObj, LVL1::JEMHits *transObj, MsgStream &log)
Definition: JEMHitsCnv_p1.cxx:24
DEBUG
#define DEBUG
Definition: page_access.h:11
python.CaloCondTools.log
log
Definition: CaloCondTools.py:20
LVL1::JEMHits
Definition: Trigger/TrigT1/TrigT1CaloEvent/TrigT1CaloEvent/JEMHits.h:27
JEMHits.h
JEMHitsCnv_p1::transToPers
virtual void transToPers(const LVL1::JEMHits *transObj, JEMHits_p1 *persObj, MsgStream &log)
Definition: JEMHitsCnv_p1.cxx:44