BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
RawDataMcCnv.hpp
Go to the documentation of this file.
1#pragma once
2
3#include "McTruth/McEvent.h"
4#include "RawDataCnv/RawDataAddress.h"
5
6#include "RawDataBaseCnv.h"
7
8extern const CLID& CLID_McEvent;
9
11public:
12 RawDataMcCnv( ISvcLocator* svc ) : RawDataBaseCnv( svc, classID() ) {}
13
14 static const CLID& classID() { return CLID_McEvent; }
15
16 StatusCode createObj( IOpaqueAddress* pAddr, DataObject*& pObj ) {
17
18 McEvent* mcEvent = new McEvent;
19 pObj = mcEvent;
20
21 return StatusCode::SUCCESS;
22 }
23
24 StatusCode createRep( DataObject* pObj, IOpaqueAddress*& pAddr ) {
25 // convert PixelRaw in the container into ByteStream
26 // MsgStream log(msgSvc(), "RawDataMcCnv");
27
28 std::string nm = pObj->registry()->name();
29
30 RawDataAddress* addr = new RawDataAddress( classID(), nm, "" );
31
32 pAddr = addr;
33
34 return StatusCode::SUCCESS;
35 }
36};
const CLID & CLID_McEvent
const CLID & CLID_McEvent
RawDataBaseCnv(long storageType, const CLID &clid, ISvcLocator *svc)
StatusCode createObj(IOpaqueAddress *pAddr, DataObject *&pObj)
StatusCode createRep(DataObject *pObj, IOpaqueAddress *&pAddr)
static const CLID & classID()
RawDataMcCnv(ISvcLocator *svc)