1#ifndef DstHltInfCnv_CXX
2#define DstHltInfCnv_CXX 1
4#include "GaudiKernel/MsgStream.h"
5#include "GaudiKernel/DataObject.h"
7#include "TClonesArray.h"
9#include "EventModel/EventModel.h"
10#include "Identifier/HltID.h"
11#include "HltEvent/HltEvent.h"
12#include "HltEvent/DstHltInf.h"
13#include "RootEventData/THltEvent.h"
14#include "RootEventData/TDstHltInf.h"
15#include "RootCnvSvc/Hlt/HltCnv.h"
16#include "RootCnvSvc/Hlt/DstHltInfCnv.h"
17#include "RootCnvSvc/RootAddress.h"
28 MsgStream log(
msgSvc(),
"DstHltInfCnv");
30 m_rootBranchname =
"m_dstHltInf";
32 m_adresses.push_back(&m_dstHltInf);
39 MsgStream log(
msgSvc(),
"DstHltInfCnv");
40 log << MSG::DEBUG <<
"DstHltInfCnv::TObjectToDataObject" << endreq;
41 StatusCode sc=StatusCode::SUCCESS;
45 refpObject=dstHltInfTds;
48 if(!m_dstHltInf)
return sc;
64 uint32_t ncon= m_dstHltInf->
getNCON();
65 uint32_t nmdc= nsub &0XFF;
66 uint32_t ntof=(nsub>>8 )&0XFF;
67 uint32_t nemc=(nsub>>16)&0XFF;
68 uint32_t nmuc=(nsub>>24)&0XFF;
69 uint32_t ncgem= nsub>>32;
89 return StatusCode::SUCCESS;
94 MsgStream log(
msgSvc(),
"DstHltInfCnv");
95 log << MSG::DEBUG <<
"DstHltInfCnv::DataObjectToTObject" << endreq;
96 StatusCode sc=StatusCode::SUCCESS;
99 if (!dstHltInfCnvTds) {
100 log << MSG::ERROR <<
"Could not downcast to DstHltInf" << endreq;
101 return StatusCode::FAILURE;
107 log << MSG::ERROR <<
"Could not get DstHltInf in TDS " << endreq;
108 return StatusCode::FAILURE;
113 log << MSG::ERROR <<
"DstHltInfCnv:Could not downcast to TDS DstHltInf" << endreq;
116 IOpaqueAddress *addr;
122 if (!tHltInf)
return sc;
130 Int_t nsub = dstHltInfCnvTds->
getNumber();
131 Int_t ncon = dstHltInfCnvTds->
getNCON();
145 return StatusCode::SUCCESS;
virtual StatusCode DataObjectToTObject(DataObject *obj, RootAddress *addr)
transformation to root
virtual StatusCode TObjectToDataObject(DataObject *&obj)
transformation from root
DstHltInfCnv(ISvcLocator *svc)
void setAlgProcess(const unsigned int i)
void setCriteriaTable(const unsigned int i)
float getTotalEnergy() const
uint32_t getCriteriaTable() const
void setNumber(const unsigned int i)
void setNCON(const unsigned int i)
uint32_t getVersion() const
uint32_t getNumber() const
uint32_t getEventType() const
uint32_t getAlgProcess() const
void setEventType(const unsigned int i)
void setTotalEnergy(const float etot)
void setVersion(const unsigned int i)
static THltEvent * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
static unsigned int getID_MUC_MAX()
static unsigned int getID_CGEM_MAX()
static unsigned int getID_EMC_MAX()
static unsigned int getID_MDC_MAX()
static unsigned int getID_TOF_MAX()
Definition of a Root address, derived from IOpaqueAddress.
Base class for all Root Converters.
IDataProviderSvc * m_eds
pointer to eventdataservice
virtual StatusCode createRep(DataObject *pObject, IOpaqueAddress *&refpAddress)
Convert the transient object to the requested representation.
void setNCON(const Int_t i)
void setVersion(const Int_t i)
void setNumber(const Int_t i)
Int_t getAlgProcess() const
void setTotalEnergy(const Double_t etot)
Double_t getTotalEnergy() const
Int_t getEventType() const
void setEventType(const Int_t i)
void setCriteriaTable(const Int_t i)
Int_t getCriteriaTable() const
void setAlgProcess(const Int_t i)
void addDstHltInf(TDstHltInf *dstHltInf)
const TDstHltInf * getDstHltInf() const
_EXTERN_ std::string Event