ATLAS Offline Software
Loading...
Searching...
No Matches
ExampleL1TriggerByteStreamTool.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TRIGT1RESULTBYTESTREAM_EXAMPLEL1TRIGGERBYTESTREAMTOOL_H
6#define TRIGT1RESULTBYTESTREAM_EXAMPLEL1TRIGGERBYTESTREAMTOOL_H
7
8// Trigger includes
11
12// Athena includes
14
15// Gaudi includes
16#include "Gaudi/Property.h"
17
27class ExampleL1TriggerByteStreamTool : public extends<AthAlgTool, IL1TriggerByteStreamTool> {
28public:
29 ExampleL1TriggerByteStreamTool(const std::string& type, const std::string& name, const IInterface* parent);
30 virtual ~ExampleL1TriggerByteStreamTool() override = default;
31
32 // ------------------------- IAlgTool methods --------------------------------
33 virtual StatusCode initialize() override;
34
35 // ------------------------- IL1TriggerByteStreamTool methods ----------------
37 virtual StatusCode convertFromBS(const std::vector<const OFFLINE_FRAGMENTS_NAMESPACE::ROBFragment*>& vrobf,
38 const EventContext& eventContext) const override;
40 virtual StatusCode convertToBS(std::vector<OFFLINE_FRAGMENTS_NAMESPACE_WRITE::ROBFragment*>& vrobf,
41 const EventContext& eventContext) override;
43 virtual const std::vector<uint32_t>& robIds() const override {return m_robIds.value();}
44
45private:
46 // ------------------------- Properties --------------------------------------
47 // ROBIDs property required by the interface
48 Gaudi::Property<std::vector<uint32_t>> m_robIds {
49 this, "ROBIDs", {}, "List of ROB IDs required for conversion to/from xAOD RoI"};
50
51 // Only write key should be set to non-empty string in python configuration if the tool is in BS->xAOD mode of operation
53 this, "MuonRoIContainerWriteKey", "", "Write handle key to MuonRoIContainer for conversion from ByteStream"};
54 // Only read key should be set to non-empty string in python configuration if the tool is in xAOD->BS mode of operation
56 this, "MuonRoIContainerReadKey", "", "Read handle key to MuonRoIContainer for conversion to ByteStream"};
57
58};
59
60#endif // TRIGT1RESULTBYTESTREAM_EXAMPLEL1TRIGGERBYTESTREAMTOOL_H
SG::ReadHandleKey< xAOD::MuonRoIContainer > m_roiReadKey
virtual StatusCode convertFromBS(const std::vector< const OFFLINE_FRAGMENTS_NAMESPACE::ROBFragment * > &vrobf, const EventContext &eventContext) const override
BS->xAOD conversion.
ExampleL1TriggerByteStreamTool(const std::string &type, const std::string &name, const IInterface *parent)
Gaudi::Property< std::vector< uint32_t > > m_robIds
virtual StatusCode convertToBS(std::vector< OFFLINE_FRAGMENTS_NAMESPACE_WRITE::ROBFragment * > &vrobf, const EventContext &eventContext) override
xAOD->BS conversion
virtual ~ExampleL1TriggerByteStreamTool() override=default
SG::WriteHandleKey< xAOD::MuonRoIContainer > m_roiWriteKey
virtual const std::vector< uint32_t > & robIds() const override
Declare ROB IDs for conversion.
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid from which a WriteHandle is made.