ATLAS Offline Software
xAODEnergySumRoIAuxInfoCnv_v1.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // $Id$
6 
7 // System include(s):
8 #include <stdexcept>
9 
10 // Gaudi/Athena include(s):
11 #include "GaudiKernel/MsgStream.h"
12 
13 // EDM include(s):
19 
20 // Local include(s):
22 
24 #define MSGLVL MSG::INFO
25 
27 #define ATH_MSG( MSG ) \
28  do { \
29  if( log.level() <= MSGLVL ) { \
30  log << MSGLVL << MSG << endmsg; \
31  } \
32  } while( 0 )
33 
35 {
36 }
37 
41  MsgStream& /*log*/ ) const {
42 
43  // Greet the user:
44  //ATH_MSG( "Converting xAOD::EnergySumRoIAuxInfo_v1 to current version..." );
45 
46  xAOD::EnergySumRoI_v1 oldRoI;
47  xAOD::EnergySumRoI_v2 newRoI;
48  oldRoI.setStore(oldObj);
49  newRoI.setStore(newObj);
50 
51  uint32_t word0 = oldRoI.roiWord0();
52  uint32_t word1 = oldRoI.roiWord1();
53  uint32_t word2 = oldRoI.roiWord2();
54  float_t ex = oldRoI.energyX();
55  float_t ey = oldRoI.energyY();
56  float_t et = oldRoI.energyT();
57 
58  newRoI.initialize(word0, word1, word2, ex, ey, et);
59 
60  return;
61 }
62 
65  MsgStream& log ) const {
66 
67  log << MSG::ERROR
68  << "Somebody called xAODEnergySumRoIAuxInfoCnv_v1::transToPers"
69  << endmsg;
70  throw std::runtime_error( "Somebody called xAODEnergySumRoIAuxInfoCnv_v1::"
71  "transToPers" );
72 
73  return;
74 }
et
Extra patterns decribing particle interation process.
xAOD::word1
word1
Definition: eFexEMRoI_v1.cxx:87
xAODEnergySumRoIAuxInfoCnv_v1::persToTrans
virtual void persToTrans(const xAOD::EnergySumRoIAuxInfo_v1 *oldObj, xAOD::EnergySumRoIAuxInfo *newObj, MsgStream &log) const override
Function converting from the old type to the current one.
Definition: xAODEnergySumRoIAuxInfoCnv_v1.cxx:39
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
xAOD::EnergySumRoIAuxInfo_v1
Auxiliary store for an EnergySum RoI object.
Definition: EnergySumRoIAuxInfo_v1.h:34
xAOD::EnergySumRoI_v1
Class describing a LVL1 energy-sum "RoI".
Definition: EnergySumRoI_v1.h:35
EnergySumRoI_v1.h
EnergySumRoIAuxInfo.h
xAODEnergySumRoIAuxInfoCnv_v1::transToPers
virtual void transToPers(const xAOD::EnergySumRoIAuxInfo *, xAOD::EnergySumRoIAuxInfo_v1 *, MsgStream &log) const override
Function for converting from old type to current one.
Definition: xAODEnergySumRoIAuxInfoCnv_v1.cxx:63
xAODEnergySumRoIAuxInfoCnv_v1::xAODEnergySumRoIAuxInfoCnv_v1
xAODEnergySumRoIAuxInfoCnv_v1()
Default constructor.
Definition: xAODEnergySumRoIAuxInfoCnv_v1.cxx:34
EnergySumRoIAuxInfo_v1.h
xAODEnergySumRoIAuxInfoCnv_v1.h
xAOD::EnergySumRoI_v1::energyX
float energyX() const
The total energy deposited in the X direction.
xAOD::EnergySumRoIAuxInfo_v2
Auxiliary store for an EnergySum RoI object.
Definition: EnergySumRoIAuxInfo_v2.h:34
copyAuxStoreThinned.h
Helper to copy an aux store while applying thinning.
SG::AuxElement::setStore
void setStore(const SG::IConstAuxStore *store)
Set the store associated with this object.
Definition: AuxElement.cxx:241
xAOD::EnergySumRoI_v1::energyY
float energyY() const
The total energy deposited in the Y direction.
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
xAOD::EnergySumRoI_v1::roiWord1
uint32_t roiWord1() const
The second RoI word produced by the L1Calo hardware.
EnergySumRoI_v2.h
xAOD::EnergySumRoI_v1::roiWord0
uint32_t roiWord0() const
The first RoI word produced by the L1Calo hardware.
xAOD::EnergySumRoI_v1::energyT
float energyT() const
The deposited total transverse energy.
xAOD::EnergySumRoI_v2::initialize
void initialize(uint32_t roiword0, uint32_t roiword1, uint32_t roiword2, float energyX, float energyY, float energyT)
Initialise the object with its most important properties from a single RoI.
Definition: EnergySumRoI_v2.cxx:25
python.CaloCondTools.log
log
Definition: CaloCondTools.py:20
xAOD::EnergySumRoI_v1::roiWord2
uint32_t roiWord2() const
The third RoI word produced by the L1Calo hardware.
xAOD::EnergySumRoI_v2
Class describing a LVL1 energy-sum "RoI".
Definition: EnergySumRoI_v2.h:35