ATLAS Offline Software
Loading...
Searching...
No Matches
sTgcRdoToPrepDataToolMT.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef MUONTGC_CNVTOOLS_sTgcRdoToPrepDataToolMT
6#define MUONTGC_CNVTOOLS_sTgcRdoToPrepDataToolMT
7
10#include "GaudiKernel/ServiceHandle.h"
11#include "GaudiKernel/ToolHandle.h"
12
28
29namespace MuonGMR4{
31}
32
33namespace Muon
34{
38
39 class sTgcRdoToPrepDataToolMT : public extends<AthAlgTool, IMuonRdoToPrepDataTool>
40 {
41 public:
43 using base_class::base_class;
44
46 virtual ~sTgcRdoToPrepDataToolMT()=default;
47
49 virtual StatusCode initialize() override;
50
56
57 StatusCode decode(const EventContext& ctx, const std::vector<IdentifierHash>& idVect) const override;
58 StatusCode decode(const EventContext& ctx, const std::vector<uint32_t>& robIds) const override;
59 StatusCode provideEmptyContainer(const EventContext& ctx) const override;
60
61 protected:
93
94 StatusCode processCollection(const EventContext& ctx,
95 DataCache& xAODcontainers,
96 const STGC_RawDataCollection *rdoColl) const;
97
98 DataCache setupOutputContainers(const EventContext& ctx) const;
99 const STGC_RawDataContainer* getRdoContainer(const EventContext& ctx) const;
100
101 void processRDOContainer(const EventContext& ctx,
102 DataCache& xAODcontainers,
103 const std::vector<IdentifierHash>& idsToDecode) const;
104
105 SG::ReadCondHandleKey<MuonGM::MuonDetectorManager> m_muDetMgrKey {this, "DetectorManagerKey", "MuonDetectorManager", "Key of input MuonDetectorManager condition data"};
106
107 ServiceHandle<IMuonIdHelperSvc> m_idHelperSvc {this, "MuonIdHelperSvc", "MuonIdHelperSvc/MuonIdHelperSvc"};
108
109
110 SG::ReadHandleKey<STGC_RawDataContainer> m_rdoContainerKey{this, "InputCollection", "sTGCRDO", "RDO container to read"};
111 PrdKey_t m_stgcPrepDataContainerKey{this, "OutputCollection", "STGC_Measurements", "sTgcPrepDataContainer to record"};
112 Gaudi::Property<bool> m_merge{this, "Merge", true}; // merge Prds
113
114 ToolHandle<ISTgcClusterBuilderTool> m_clusterBuilderTool{this,"ClusterBuilderTool","SimpleSTgcClusterBuilderTool/SimpleSTgcClusterBuilderTool"};
115 ToolHandle<INSWCalibTool> m_calibTool{this,"NSWCalibTool", ""};
116
118 SG::UpdateHandleKey<sTgcPrepDataCollection_Cache> m_prdContainerCacheKey{this, "PrdCacheKey", "", "Optional external cache for the sTGC PRD container"};
119
120 // xAOD output containers keys
121 SG::WriteHandleKey<xAOD::sTgcStripContainer> m_xAODStripKey{this, "xAODStripKey", "", "If empty, do not produce xAOD, otherwise this is the key of the output xAOD MDT PRD container"};
122 SG::WriteHandleKey<xAOD::sTgcPadContainer> m_xAODPadKey{this, "xAODPadKey", "", "If empty, do not produce xAOD, otherwise this is the key of the output xAOD MDT PRD container"};
123 SG::WriteHandleKey<xAOD::sTgcWireContainer> m_xAODWireKey{this, "xAODWireKey", "", "If empty, do not produce xAOD, otherwise this is the key of the output xAOD MDT PRD container"};
124
125 Gaudi::Property<bool> m_useNewGeo{this, "UseR4DetMgr", false,
126 "Switch between the legacy and the new geometry"};
127
129
130
131 };
132} // end of namespace
133
134#endif // MUONTGC_CNVTOOLS_STGCRDOTOPREPDATATOOL_H
StatusCode provideEmptyContainer(const EventContext &ctx) const override
virtual ~sTgcRdoToPrepDataToolMT()=default
Destructor.
void processRDOContainer(const EventContext &ctx, DataCache &xAODcontainers, const std::vector< IdentifierHash > &idsToDecode) const
ToolHandle< INSWCalibTool > m_calibTool
ToolHandle< ISTgcClusterBuilderTool > m_clusterBuilderTool
SG::ReadHandleKey< STGC_RawDataContainer > m_rdoContainerKey
StatusCode processCollection(const EventContext &ctx, DataCache &xAODcontainers, const STGC_RawDataCollection *rdoColl) const
SG::WriteHandleKey< xAOD::sTgcWireContainer > m_xAODWireKey
SG::UpdateHandleKey< sTgcPrepDataCollection_Cache > m_prdContainerCacheKey
This is the key for the cache for the sTGC PRD containers, can be empty.
const MuonGMR4::MuonDetectorManager * m_detMgrR4
ServiceHandle< IMuonIdHelperSvc > m_idHelperSvc
SG::WriteHandleKey< xAOD::sTgcStripContainer > m_xAODStripKey
SG::WriteHandleKey< xAOD::sTgcPadContainer > m_xAODPadKey
StatusCode decode(const EventContext &ctx, const std::vector< IdentifierHash > &idVect) const override
Decode RDO to PRD A vector of IdentifierHash are passed in, and the data corresponding to this list...
DataCache setupOutputContainers(const EventContext &ctx) const
SG::WriteHandleKey< sTgcPrepDataContainer > PrdKey_t
const STGC_RawDataContainer * getRdoContainer(const EventContext &ctx) const
virtual StatusCode initialize() override
Standard AthAlgTool initialize method.
SG::ReadCondHandleKey< MuonGM::MuonDetectorManager > m_muDetMgrKey
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid from which an UpdateHandle is made.
Property holding a SG store/key/clid from which a WriteHandle is made.
The ReadoutGeomCnvAlg converts the Run4 Readout geometry build from the GeoModelXML into the legacy M...
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
MuonPrepDataCollection< sTgcPrepData > sTgcPrepDataCollection
sTgcPadAuxContainer_v1 sTgcPadAuxContainer
sTgcStripContainer_v1 sTgcStripContainer
sTgcWireContainer_v1 sTgcWireContainer
sTgcWireAuxContainer_v1 sTgcWireAuxContainer
sTgcStripAuxContainer_v1 sTgcStripAuxContainer
sTgcPadContainer_v1 sTgcPadContainer
Data cache to hold the translated prd & xAOD containers.
void translateAndSort(sTgcPrepDataCollection &coll)
std::vector< std::unique_ptr< sTgcPrepDataCollection > > collections
DataCache(const std::size_t hashMax, const PrdKey_t &key, const EventContext &ctx)
DataCache(DataCache &&other)=default
const MuonGMR4::MuonDetectorManager * detMgr
xAOD::FillContainer< xAOD::sTgcWireContainer, xAOD::sTgcWireAuxContainer > WireCont_t
xAOD::FillContainer< xAOD::sTgcStripContainer, xAOD::sTgcStripAuxContainer > StripCont_t
SG::WriteHandle< sTgcPrepDataContainer > prdWriteHandle
xAOD::FillContainer< xAOD::sTgcPadContainer, xAOD::sTgcPadAuxContainer > PadCont_t
DataCache & operator=(DataCache &&other)=default