ATLAS Offline Software
Loading...
Searching...
No Matches
TRT_LayerBuilderCond.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
6//Trk
9// InDetDD
11// Athena
13
14// constructor
15InDet::TRT_LayerBuilderCond::TRT_LayerBuilderCond(const std::string& t, const std::string& n, const IInterface* p) :
16 base_class(t,n,p)
17{
18}
19
20
21// Athena standard methods
22// initialize
24{
25 ATH_MSG_DEBUG( "initialize()" );
26 // get TRT Detector Description
27 ATH_CHECK(m_readKeyTRTContainer.initialize());
28 return StatusCode::SUCCESS;
29}
30
31
33std::unique_ptr<const std::vector<Trk::CylinderLayer*> >
36{
38 const InDetDD::TRT_DetElementContainer* trtContainer{*readHandleTRTContainer};
39 if(trtContainer == nullptr){
40 ATH_MSG_ERROR("Aligned TRT could not be retrieved from CondStore: " << m_readKeyTRTContainer);
41 return nullptr;
42 }
43 whandle.addDependency (readHandleTRTContainer);
44 return cylindricalLayersImpl(trtContainer);
45}
46
47
49std::unique_ptr<const std::vector<Trk::DiscLayer*> >
52{
54 const InDetDD::TRT_DetElementContainer* trtContainer{*readHandleTRTContainer};
55 if(trtContainer == nullptr){
56 ATH_MSG_ERROR("Aligned TRT could not be retrieved from CondStore: " << m_readKeyTRTContainer);
57 return nullptr;
58 }
59 whandle.addDependency (readHandleTRTContainer);
60 return discLayersImpl(trtContainer);
61}
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_ERROR(x)
#define ATH_MSG_DEBUG(x)
Class to hold different TRT detector elements structures.
SG::ReadCondHandleKey< InDetDD::TRT_DetElementContainer > m_readKeyTRTContainer
virtual std::unique_ptr< const std::vector< Trk::DiscLayer * > > discLayers(const EventContext &ctx, SG::WriteCondHandle< Trk::TrackingGeometry > &whandle) const override final
LayerBuilderCond interface method - returning Endcap-like layers.
virtual std::unique_ptr< const std::vector< Trk::CylinderLayer * > > cylindricalLayers(const EventContext &ctx, SG::WriteCondHandle< Trk::TrackingGeometry > &whandle) const override final
LayerBuilderCond interface method - returning Barrel-like layers.
TRT_LayerBuilderCond(const std::string &, const std::string &, const IInterface *)
AlgTool style constructor.
virtual StatusCode initialize() override final
AlgTool initialize method.
void addDependency(const EventIDRange &range)