ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
HLT
Event
TrigByteStreamCnvSvc
src
TrigByteStreamInputSvc.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef TRIGBYTESTREAMINPUTSVC_H
6
#define TRIGBYTESTREAMINPUTSVC_H
7
8
#include "
ByteStreamCnvSvcBase/IByteStreamInputSvc.h
"
9
#include "
ByteStreamCnvSvcBase/IROBDataProviderSvc.h
"
10
#include "
ByteStreamData/RawEvent.h
"
11
#include "
AthenaBaseComps/AthService.h
"
12
#include "
AthenaKernel/SlotSpecificObj.h
"
13
#include "
AthenaMonitoringKernel/Monitored.h
"
14
#include "
EFInterfaceSvc.h
"
15
#include <memory.h>
16
17
// Forward declarations
18
class
StoreGateSvc
;
19
25
class
TrigByteStreamInputSvc
:
public
extends<AthService, IByteStreamInputSvc> {
26
public
:
28
TrigByteStreamInputSvc
(
const
std::string& name, ISvcLocator* svcLoc);
30
virtual
~TrigByteStreamInputSvc
();
31
32
// Helper for swapping between the 2 interfaces enum
33
enum class
NextEventStatus
{
OK
,
NO_EVENT
,
STOP
,
ERROR
};
34
35
// ------------------------- Service methods --------------------------------
36
virtual
StatusCode
initialize
()
override
;
37
virtual
StatusCode
finalize
()
override
;
38
39
// ------------------------- ByteStreamInputSvc methods ----------------------
40
virtual
const
RawEvent
*
nextEvent
()
override
;
41
virtual
const
RawEvent
*
previousEvent
()
override
;
42
virtual
const
RawEvent
*
currentEvent
()
const override
;
43
44
private
:
45
// ------------------------- Service handles ---------------------------------
46
ServiceHandle<IROBDataProviderSvc>
m_robDataProviderSvc
{
this
,
"ROBDataProvider"
,
"ROBDataProviderSvc"
};
47
ServiceHandle<EFInterfaceSvc>
m_efInterfaceSvc
{
this
,
"EFInterfaceSvc"
,
""
,
"Online service managing EF interface with Dataflow"
};
48
ServiceHandle<StoreGateSvc>
m_evtStore
{
this
,
"EventStore"
,
"StoreGateSvc"
};
49
ToolHandle<GenericMonitoringTool>
m_monTool
{
this
,
"MonTool"
,
""
,
"Monitoring tool"
};
50
51
// ------------------------- Properties --------------------------------------
52
Gaudi::Property<int>
m_checkCTPFragmentModuleID
{
this
,
"CheckCTPFragmentModuleID"
, -1,
53
"After reading a new event, assert we can retrieve the CTP fragment with Module ID given by this property, "
54
"and that has no errors. A value <0 disables the check."
};
55
56
// ------------------------- Private data members ----------------------------
57
struct
EventCache
{
58
~EventCache
() =
default
;
59
void
releaseEvent
();
60
std::unique_ptr<RawEvent>
fullEventFragment
{
nullptr
};
61
std::unique_ptr<uint32_t[]>
rawData
{
nullptr
};
62
};
63
64
SG::SlotSpecificObj<EventCache>
m_eventsCache
;
65
uint16_t
m_maxLB
{0};
66
bool
m_hasEFInterface
{
false
};
67
};
68
69
#endif
// TRIGBYTESTREAMINPUTSVC_H
AthService.h
SlotSpecificObj.h
Maintain a set of objects, one per slot.
EFInterfaceSvc.h
IByteStreamInputSvc.h
This file contains the interface for the ByteStreamInputSvc classes.
IROBDataProviderSvc.h
Monitored.h
Header file to be included by clients of the Monitored infrastructure.
RawEvent.h
RawEvent
OFFLINE_FRAGMENTS_NAMESPACE::FullEventFragment RawEvent
data type for reading raw event
Definition
RawEvent.h:37
SG::SlotSpecificObj
Maintain a set of objects, one per slot.
Definition
AthenaKernel/AthenaKernel/SlotSpecificObj.h:84
ServiceHandle
Definition
ClusterMakerTool.h:36
StoreGateSvc
The Athena Transient Store API.
Definition
StoreGateSvc.h:120
TrigByteStreamInputSvc::currentEvent
virtual const RawEvent * currentEvent() const override
Definition
TrigByteStreamInputSvc.cxx:219
TrigByteStreamInputSvc::NextEventStatus
NextEventStatus
Definition
TrigByteStreamInputSvc.h:33
TrigByteStreamInputSvc::NextEventStatus::NO_EVENT
@ NO_EVENT
Definition
TrigByteStreamInputSvc.h:33
TrigByteStreamInputSvc::NextEventStatus::STOP
@ STOP
Definition
TrigByteStreamInputSvc.h:33
TrigByteStreamInputSvc::NextEventStatus::ERROR
@ ERROR
Definition
TrigByteStreamInputSvc.h:33
TrigByteStreamInputSvc::NextEventStatus::OK
@ OK
Definition
TrigByteStreamInputSvc.h:33
TrigByteStreamInputSvc::TrigByteStreamInputSvc
TrigByteStreamInputSvc(const std::string &name, ISvcLocator *svcLoc)
Standard constructor.
Definition
TrigByteStreamInputSvc.cxx:35
TrigByteStreamInputSvc::m_efInterfaceSvc
ServiceHandle< EFInterfaceSvc > m_efInterfaceSvc
Definition
TrigByteStreamInputSvc.h:47
TrigByteStreamInputSvc::m_maxLB
uint16_t m_maxLB
Maximum lumi block number seen so far, used for monitoring.
Definition
TrigByteStreamInputSvc.h:65
TrigByteStreamInputSvc::previousEvent
virtual const RawEvent * previousEvent() override
Definition
TrigByteStreamInputSvc.cxx:211
TrigByteStreamInputSvc::m_hasEFInterface
bool m_hasEFInterface
Definition
TrigByteStreamInputSvc.h:66
TrigByteStreamInputSvc::nextEvent
virtual const RawEvent * nextEvent() override
Definition
TrigByteStreamInputSvc.cxx:87
TrigByteStreamInputSvc::m_eventsCache
SG::SlotSpecificObj< EventCache > m_eventsCache
Cache of RawEvent pointer per event slot.
Definition
TrigByteStreamInputSvc.h:64
TrigByteStreamInputSvc::~TrigByteStreamInputSvc
virtual ~TrigByteStreamInputSvc()
Standard destructor.
Definition
TrigByteStreamInputSvc.cxx:41
TrigByteStreamInputSvc::finalize
virtual StatusCode finalize() override
Definition
TrigByteStreamInputSvc.cxx:70
TrigByteStreamInputSvc::m_checkCTPFragmentModuleID
Gaudi::Property< int > m_checkCTPFragmentModuleID
Definition
TrigByteStreamInputSvc.h:52
TrigByteStreamInputSvc::m_robDataProviderSvc
ServiceHandle< IROBDataProviderSvc > m_robDataProviderSvc
Definition
TrigByteStreamInputSvc.h:46
TrigByteStreamInputSvc::m_monTool
ToolHandle< GenericMonitoringTool > m_monTool
Definition
TrigByteStreamInputSvc.h:49
TrigByteStreamInputSvc::m_evtStore
ServiceHandle< StoreGateSvc > m_evtStore
Definition
TrigByteStreamInputSvc.h:48
TrigByteStreamInputSvc::initialize
virtual StatusCode initialize() override
Definition
TrigByteStreamInputSvc.cxx:46
TrigByteStreamInputSvc::EventCache
Definition
TrigByteStreamInputSvc.h:57
TrigByteStreamInputSvc::EventCache::~EventCache
~EventCache()=default
TrigByteStreamInputSvc::EventCache::releaseEvent
void releaseEvent()
Definition
TrigByteStreamInputSvc.cxx:225
TrigByteStreamInputSvc::EventCache::rawData
std::unique_ptr< uint32_t[]> rawData
Underlying data structure.
Definition
TrigByteStreamInputSvc.h:61
TrigByteStreamInputSvc::EventCache::fullEventFragment
std::unique_ptr< RawEvent > fullEventFragment
Current event fragment.
Definition
TrigByteStreamInputSvc.h:60
Generated on
for ATLAS Offline Software by
1.17.0