1#include "GaudiKernel/MsgStream.h"
12#include "GaudiKernel/CnvFactory.h"
13#include "GaudiKernel/IOpaqueAddress.h"
14#include "GaudiKernel/DataObject.h"
15#include "GaudiKernel/IAddressCreator.h"
16#include "GaudiKernel/IDataProviderSvc.h"
17#include "GaudiKernel/IConversionSvc.h"
18#include "GaudiKernel/GenericAddress.h"
46 DataObject*& refpObject) {
48 MsgStream log(
msgSvc(),
"TreeEsTimeCalibDataCnv");
49 log<<MSG::DEBUG<<
"SetProperty"<<endreq;
53 TBufferFile *buf1 =
new TBufferFile(TBuffer::kRead);
54 TBufferFile *buf2 =
new TBufferFile(TBuffer::kRead);
55 buf1->SetBuffer((*records)[
"EsTimeH2"],512000,kFALSE);
56 buf2->SetBuffer((*records)[
"EsTimeH9"],512000,kFALSE);
58 std::cout<<
" SftVer is "<<(*records)[
"SftVer"];
59 std::cout<<
" CalVerSft is "<<(*records)[
"CalParVer"];
60 std::cout<<
" File name is "<<(*records)[
"FileName"]<<std::endl;
62 TTree* Testtree=
new TTree();
64 Testtree->Streamer(*buf1);
65 TTree* tree2=
new TTree();
66 tree2->Streamer(*buf2);
73 double EsTimeCalibConst;
74 vector<double> TestCalibConst;
76 int no= Testtree -> GetEntries();
78 Testtree->GetEntry(i);
79 TestCalibConst.push_back(EsTimeCalibConst);
81 tmpObject -> setTestCalibConst(&TestCalibConst);
83 double t0offsete,t0offsetb;
85 tree2->SetBranchAddress(
"t0offsete", &t0offsete);
86 tree2->SetBranchAddress(
"t0offsetb", &t0offsetb);
87 tree2->SetBranchAddress(
"bunchtime", &bunchtime);
96 return StatusCode::SUCCESS;
const CLID CLID_Calib_EsTimeCal
data SetBranchAddress("time",&time)
void setToffsetb(const double toffsetb)
void setBunchTime(const int bunchtime)
void setToffsete(const double toffsete)
virtual DatabaseRecord * pp()
static const CLID & classID()
TreeEsTimeCalibDataCnv(ISvcLocator *svc)
const CLID & objType() const
virtual StatusCode i_createObj(IOpaqueAddress *address, DataObject *&refpObject)