Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2023-10-25 10:03:28

0001 #ifndef _VertexReconstructor_H_
0002 #define _VertexReconstructor_H_
0003 
0004 #include "RecoVertex/VertexPrimitives/interface/TransientVertex.h"
0005 #include "TrackingTools/TransientTrack/interface/TransientTrack.h"
0006 #include "DataFormats/BeamSpot/interface/BeamSpot.h"
0007 #include <vector>
0008 
0009 /** Abstract class for vertex reconstructors, 
0010  *  i.e. objects reconstructing vertices using a set of TransientTracks
0011  */
0012 
0013 class VertexReconstructor {
0014 public:
0015   VertexReconstructor() {}
0016   virtual ~VertexReconstructor() {}
0017 
0018   /** Reconstruct vertices
0019    */
0020   virtual std::vector<TransientVertex> vertices(const std::vector<reco::TransientTrack> &) const = 0;
0021 
0022   /** Reconstruct vertices, exploiting the beamspot constraint
0023    *  for the primary vertex
0024    */
0025   virtual std::vector<TransientVertex> vertices(const std::vector<reco::TransientTrack> &t,
0026                                                 const reco::BeamSpot &) const {
0027     return vertices(t);
0028   }
0029 
0030   /** Reconstruct vertices, but exploit the fact that you know
0031    *  that some tracks cannot come from a secondary vertex.
0032    *  \paramname primaries Tracks that _cannot_ come from
0033    *  a secondary vertex (but can, in principle, be
0034    *  non-primaries, also).
0035    *  \paramname tracks These are the tracks that are of unknown origin. These
0036    *  tracks are subjected to pattern recognition.
0037    *  \paramname spot A beamspot constraint is mandatory in this method.
0038    */
0039   virtual std::vector<TransientVertex> vertices(const std::vector<reco::TransientTrack> &primaries,
0040                                                 const std::vector<reco::TransientTrack> &tracks,
0041                                                 const reco::BeamSpot &spot) const {
0042     return vertices(tracks, spot);
0043   }
0044 
0045   virtual VertexReconstructor *clone() const = 0;
0046 };
0047 
0048 #endif