25#include "GaudiKernel/EventContext.h"
51 return StatusCode::SUCCESS;
59 const EventContext& ctx = Gaudi::Hive::currentContext();
65 std::pair<xAOD::VertexContainer*,xAOD::VertexAuxContainer*> theXAODContainers
66 = std::make_pair( theXAODContainer, theXAODAuxContainer );
84 ATH_MSG_WARNING(
"couldn't retrieve Primary vertex, keeping privtx_z0 = 0 ");
87 std::unique_ptr<Trk::VxSecVertexInfo> foundVrts;
95 std::pair<xAOD::VertexContainer*, xAOD::VertexAuxContainer*> myVxContainers = std::make_pair( myVertexContainer, myVertexAuxContainer );
96 ATH_MSG_DEBUG(
"Vertexing done, sorting the vertex container");
97 if (theXAODContainers.first) {
100 myVxContainers.first = theXAODContainers.first;
101 myVxContainers.second = theXAODContainers.second;
103 if (myVxContainers.first == 0) {
106 return StatusCode::SUCCESS;
109 if (not myVxContainers.first->hasStore()) {
112 return StatusCode::SUCCESS;
115 ATH_MSG_DEBUG(
"Successfully reconstructed " << myVxContainers.first->size()-1 <<
" vertices (excluding dummy)");
120 ATH_CHECK(outputVertices.
record(std::unique_ptr<xAOD::VertexContainer>(myVxContainers.first),std::unique_ptr<xAOD::VertexAuxContainer>(myVxContainers.second)));
125 return StatusCode::SUCCESS;
130 ATH_MSG_DEBUG(
"Summary from Secondary Vertex Finder (InnerDetector/InDetRecAlgs/InDetSecVtxFinder)");
137 return StatusCode::SUCCESS;
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_WARNING(x)
Helper class to provide constant type-safe access to aux data.
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
unsigned int m_numEventsProcessed
StatusCode execute()
Execute method without EventContext (deprecated).
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_inputTrackParticles
unsigned int m_totalNumVerticesWithoutDummy
ToolHandle< InDet::IAdaptiveMultiSecVertexFinder > m_AdaptiveMultiVertexFinderTool
SG::WriteHandleKey< xAOD::VertexContainer > m_outputSecondaryVertices
SG::ReadHandleKey< xAOD::VertexContainer > m_inputPrimaryVertices
InDetSecVtxFinder(const std::string &name, ISvcLocator *pSvcLocator)
Helper class to provide constant type-safe access to aux data.
bool isAvailable(const ELT &e) const
Test to see if this variable exists in the store.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
const_pointer_type cptr()
Dereference the pointer.
StatusCode record(std::unique_ptr< T > data)
Record a const object to the store.
size_t nTrackParticles() const
Get the number of tracks associated with this vertex.
VxType::VertexType vertexType() const
The type of the vertex.
const Amg::Vector3D & position() const
Returns the 3-pos.
VertexAuxContainer_v1 VertexAuxContainer
Definition of the current jet auxiliary container.
VertexContainer_v1 VertexContainer
Definition of the current "Vertex container version".
Vertex_v1 Vertex
Define the latest version of the vertex class.