BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
RawDataDigiCnv.hpp
Go to the documentation of this file.
1#pragma once
2
3#include "RawDataCnv/RawDataAddress.h"
4#include "RawEvent/DigiEvent.h"
5
6#include "RawDataBaseCnv.h"
7
8extern const CLID& CLID_DigiEvent;
9
11public:
12 // Standard Constructor.
13 RawDataDigiCnv( ISvcLocator* svc ) : RawDataBaseCnv( svc, classID() ){};
14
15 // Return the class type of this converter.
16 static const CLID& classID() { return CLID_DigiEvent; }
17
18 // Create a converted object in the Transient Data Store.
19 StatusCode createObj( IOpaqueAddress* pAddr, DataObject*& pObj ) {
20 // Purpose and Method: This converter will create an empty EventHeader on
21 // the TDS.
22 DigiEvent* digi = new DigiEvent();
23 // Set fromMc to false
24 digi->initialize( false );
25 pObj = digi;
26 return StatusCode::SUCCESS;
27 }
28
29 StatusCode createRep( DataObject* pObj, IOpaqueAddress*& pAddr ) {
30 // convert Raws in the container into ByteStream
31 RawDataAddress* addr = new RawDataAddress( classID(), pObj->registry()->name(), "" );
32
33 pAddr = addr;
34 return StatusCode::SUCCESS;
35 }
36};
const CLID & CLID_DigiEvent
Raw event and Digi IDs.
const CLID & CLID_DigiEvent
Raw event and Digi IDs.
RawDataBaseCnv(long storageType, const CLID &clid, ISvcLocator *svc)
StatusCode createRep(DataObject *pObj, IOpaqueAddress *&pAddr)
static const CLID & classID()
StatusCode createObj(IOpaqueAddress *pAddr, DataObject *&pObj)
RawDataDigiCnv(ISvcLocator *svc)