|
ATLAS Offline Software
|
Go to the documentation of this file.
32 (
const std::string&
type,
33 const std::string&
name,
37 declareProperty (
"VxSGKey",
m_targetSGKey=
"VxPrimaryCandidate");
38 declareProperty (
"Fast",
m_fast =
false);
71 return p.reconstructedVertex();
78 if (
sc.isFailure() || !vxContainer) {
83 int nVx = vxContainer->
size();
88 for(
int v=0;
v<nVx-1;
v++){
90 const std::vector<Trk::VxTrackAtVertex*>* tracks = vx->
vxTrackAtVertex();
92 if(tracks) nTracks = tracks->size();
93 for(
int t=0;
t<nTracks;
t++) {
99 if(linkToTrackParticle){
101 if(particle_base == &
p){
111 return vxContainer->
at(nVx-1);
126 if (!vertices.isValid())
131 for (
const auto vx : *vertices )
133 for (
const auto& tpLink : vx->trackParticleLinks() )
141 if (foundVertex)
break;
The VxTrackAtVertex is a common class for all present TrkVertexFitters The VxTrackAtVertex is designe...
TrackParticleVertexAssociationTool(const std::string &type, const std::string &name, const IInterface *parent)
Standard Gaudi tool constructor.
virtual StatusCode addVariable(const std::string &name, const std::type_info &ti, void *&ptr, const std::string &docstring="", const void *defval=0)
Add a variable to the tuple.
virtual StatusCode book() final
book ntuple variables
virtual const Trk::VxCandidate * get(const Rec::TrackParticle &p) override
Return the target object.
Block filler tool for noisy FEB information.
std::vector< Trk::VxTrackAtVertex * > * vxTrackAtVertex(void)
Unconst pointer to the vector of tracks Required by some of the vertex fitters.
Associate from a TrackParticle to its reconstructed vertex.
::StatusCode StatusCode
StatusCode definition for legacy code.
std::string m_targetSGKey
SG key for target collection.
#define CHECK(...)
Evaluate an expression and check for errors.
bool m_fast
flag to just return whatever is returned by TrackParticle::reconstructedVertex()
Helpers for checking error return status codes and reporting errors.
#define REPORT_MESSAGE(LVL)
Report a message.
Class describing a Vertex.
virtual StatusCode initialize() override
Standard Gaudi initialize method.
#define ATH_MSG_WARNING(x)
SG::ReadHandleKey< xAOD::VertexContainer > m_vertexKey
xAOD vertex container handle key
Class describing a TrackParticle.
const T * at(size_type n) const
Access an element, as an rvalue.
float * m_weight
weight of the track at the associated vertex
size_type size() const noexcept
Returns the number of elements in the collection.