ATLAS Offline Software
TrackRetriever.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 JIVEXML_TRACKRETRIEVER_H
6 #define JIVEXML_TRACKRETRIEVER_H
7 
8 #include "GaudiKernel/ToolHandle.h"
10 #include "JiveXML/IDataRetriever.h"
12 #include "GaudiKernel/ToolHandle.h"
17 
18 //Forward declarations
19 class AtlasDetectorID;
20 
21 namespace JiveXML{
22 
60  class TrackRetriever : virtual public IDataRetriever,
61  public AthAlgTool {
62 
63  public:
64 
66  TrackRetriever(const std::string& type,const std::string& name,const IInterface* parent);
67 
68  virtual StatusCode retrieve(ToolHandle<IFormatTool> &FormatTool);
70  const DataMap getData(const TrackCollection* trackCollection, const std::string &collectionName);
72  virtual std::string dataTypeName() const { return m_typeName; };
73 
76 
77  private:
79  const std::string m_typeName = "Track";
80 
81  SG::ReadHandleKeyArray<TrackCollection> m_keys {this,"TrackCollections", {"CombinedInDetTracks","DisappearingTracks","ExtrapolatedStauTracks","ExtraPolatedMuonsLRTTracks","MSOnlyExtraPolatedMuonsLRTTrackParticlesTracks","ResolvedForwardTracks","CombinedMuonsLRTTracks","CombinedStauTracks","MuonSpectrometerTracks","MSOnlyExtrapolatedTracks","ExtrapolatedMuonTracks","CombinedMuonTracks","GSFTracks"}, "Name of the Trk TrackCollection containers that will be written out to the JiveXML file"};
82  SG::ReadHandleKeyArray<TrackTruthCollection> m_TrackTruthCollections {this,"TruthCollections", {"CombinedInDetTracksTruthCollection"}, "Name of the Truth Track containers that will be written out to the JiveXML file"};
83 
84  Gaudi::Property<bool> m_doWriteResiduals {this,"DoWriteResiduals", true,"Whether to write TrackResiduals"};
85  Gaudi::Property<bool> m_doHitsSorting {this, "DoHitsSorting", false, "Whether to perform hits TrackStateOnSurfaces (TSoS) sorting"};
86  Gaudi::Property<bool> m_doHitsDetails {this, "DoHitsDetails", true, "Whether to write hits TrackStateOnSurfaces (TSoS) details"};
87  Gaudi::Property<bool> m_isMC {this, "isMC", false, "Whether file is MC"};
88 
89  ToolHandle<Trk::IResidualPullCalculator> m_residualPullCalculator {this, "ResidualPullCalculator","Trk::ResidualPullCalculator/ResidualPullCalculator", "ToolHandle to ResidualPullCaclulator" };
90  ToolHandle< Trk::ITrackSummaryTool > m_trackSumTool{this, "TrackSummaryTool", "Trk::TrackSummaryTool/InDetTrackSummaryTool", "Track Summary Tool for number of Pix/SCT/TRT hits"};
91 
94 
95  };
96 
97 }
98 #endif
ITrackSummaryTool.h
JiveXML::TrackRetriever::initialize
StatusCode initialize()
Default AthAlgTool methods.
Definition: TrackRetriever.cxx:343
JiveXML::TrackRetriever::m_doWriteResiduals
Gaudi::Property< bool > m_doWriteResiduals
Definition: TrackRetriever.h:84
JiveXML::TrackRetriever::m_doHitsDetails
Gaudi::Property< bool > m_doHitsDetails
Definition: TrackRetriever.h:86
JiveXML::TrackRetriever::m_keys
SG::ReadHandleKeyArray< TrackCollection > m_keys
Definition: TrackRetriever.h:81
JiveXML::TrackRetriever::m_typeName
const std::string m_typeName
The data type that is generated by this retriever.
Definition: TrackRetriever.h:79
SG::HandleKeyArray
Definition: StoreGate/StoreGate/HandleKeyArray.h:38
JiveXML::TrackRetriever::retrieve
virtual StatusCode retrieve(ToolHandle< IFormatTool > &FormatTool)
For each track collection retrieve all data.
Definition: TrackRetriever.cxx:366
JiveXML::DataMap
std::map< std::string, DataVect > DataMap
Definition: DataType.h:59
JiveXML::TrackRetriever::m_residualPullCalculator
ToolHandle< Trk::IResidualPullCalculator > m_residualPullCalculator
Definition: TrackRetriever.h:89
python.CaloAddPedShiftConfig.type
type
Definition: CaloAddPedShiftConfig.py:42
TrackTruthCollection.h
JiveXML::TrackRetriever::getData
const DataMap getData(const TrackCollection *trackCollection, const std::string &collectionName)
Puts the variables into a DataMap.
Definition: TrackRetriever.cxx:388
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AthAlgTool.h
TrackCollection.h
test_pyathena.parent
parent
Definition: test_pyathena.py:15
JiveXML::IDataRetriever
Interface for all DataRetriever classes, that extract event data from StoreGate and pass them on to a...
Definition: IDataRetriever.h:25
JiveXML::TrackRetriever::m_idHelper
const AtlasDetectorID * m_idHelper
Used to find out the corresponding sub-det from ROT->identify().
Definition: TrackRetriever.h:93
DataVector< Trk::Track >
JiveXML
This header is shared inbetween the C-style server thread and the C++ Athena ServerSvc.
Definition: BadLArRetriever.cxx:22
ReadCondHandleKey.h
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:240
JiveXML::TrackRetriever::m_isMC
Gaudi::Property< bool > m_isMC
Definition: TrackRetriever.h:87
JiveXML::TrackRetriever
Retrieves the Trk::TrackCollection objects.
Definition: TrackRetriever.h:61
JiveXML::TrackRetriever::TrackRetriever
TrackRetriever(const std::string &type, const std::string &name, const IInterface *parent)
Standard Constructor.
Definition: TrackRetriever.cxx:335
JiveXML::TrackRetriever::m_doHitsSorting
Gaudi::Property< bool > m_doHitsSorting
Definition: TrackRetriever.h:85
IResidualPullCalculator.h
JiveXML::TrackRetriever::m_trackSumTool
ToolHandle< Trk::ITrackSummaryTool > m_trackSumTool
Definition: TrackRetriever.h:90
AthAlgTool
Definition: AthAlgTool.h:26
JiveXML::TrackRetriever::m_TrackTruthCollections
SG::ReadHandleKeyArray< TrackTruthCollection > m_TrackTruthCollections
Definition: TrackRetriever.h:82
AtlasDetectorID
This class provides an interface to generate or decode an identifier for the upper levels of the dete...
Definition: AtlasDetectorID.h:57
JiveXML::TrackRetriever::dataTypeName
virtual std::string dataTypeName() const
Return the name of the data type that is generated by this retriever.
Definition: TrackRetriever.h:72
IDataRetriever.h