BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
Event/RootCnvSvc/include/RootCnvSvc/EvtHeaderCnv.h
Go to the documentation of this file.
1#ifndef EvtHeaderCnv_H
2#define EvtHeaderCnv_H 1
3
4#include "RootCnvSvc/RootEventBaseCnv.h"
5
6#include "RootCnvSvc/commonData.h"
7#include "RootEventData/TEvtHeader.h"
8
9// extern const CLID& CLID_Event;
10extern const CLID& CLID_EventHeader;
11
12// Abstract factory to create the converter
13template <class TYPE> class CnvFactory;
14
15/** @class EvtHeaderCnv
16 * @brief Concrete converter for the EvtHeader branch
17 *
18 * Based on the EvtHeaderCnv of GLAST.
19 */
20
22
23 friend class CnvFactory<EvtHeaderCnv>;
24
25public:
26 static const CLID& classID() { return CLID_EventHeader; }
27
28 virtual ~EvtHeaderCnv() {};
29
30 virtual StatusCode initialize();
31
32 /// returns object to be written (maintained here for all DIGI-converters)
33 static TEvtHeader* getWriteObject() { return m_objWrite; }
34
35 EvtHeaderCnv( ISvcLocator* svc );
36
37 /// transformation from TDS object to ROOT
38 virtual StatusCode DataObjectToTObject( DataObject* obj, RootAddress* addr );
39
40 /// do the transformation from ROOT to TDS object
41 virtual StatusCode TObjectToDataObject( DataObject*& refpObject );
42
43private:
44 /// Root object to be written
45 static TEvtHeader* m_objWrite;
46
47 /// Run number
48 Int_t m_runId{ 0 };
49 /// Event Number
50 Int_t m_eventId{ 0 };
51
52 UInt_t m_time{ 0 };
53
54 /// EventTag
55 UInt_t m_eventTag{ 0 };
56
57 /// Flags
58 UInt_t m_flag1{ 0 };
59 UInt_t m_flag2{ 0 };
60
61 /// ETS
62 ULong_t m_etsT1{ 0 };
63 ULong_t m_etsT2{ 0 };
64
65 // Int_t* m_data;
66 Int_t m_data[10]{};
67
68 commonData m_common;
69};
70
71#endif // EvtHeaderCnv_H
const CLID & CLID_EventHeader
static TEvtHeader * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
virtual StatusCode DataObjectToTObject(DataObject *obj, RootAddress *addr)
transformation from TDS object to ROOT
virtual StatusCode TObjectToDataObject(DataObject *&refpObject)
do the transformation from ROOT to TDS object
virtual StatusCode initialize()
EvtHeaderCnv(ISvcLocator *svc)
Definition of a Root address, derived from IOpaqueAddress.
RootEventBaseCnv(const CLID &clid, ISvcLocator *svc)