1 #ifndef TemplatedVertexArbitrator_h 2 #define TemplatedVertexArbitrator_h 51 template <
class InputContainer,
class VTX>
71 template <
class InputContainer,
class VTX>
82 template <
class InputContainer,
class VTX>
94 auto recoVertices = std::make_unique<Product>();
95 if(primaryVertices->size()!=0){
109 for(
typename InputContainer::const_iterator
track = tracks->begin();
119 for(
unsigned int ivtx=0; ivtx < theRecoVertices.size(); ivtx++){
120 if ( !(
nTracks(theRecoVertices[ivtx]) > 1) )
continue;
121 recoVertices->push_back(theRecoVertices[ivtx]);
edm::EDGetTokenT< reco::BeamSpot > token_beamSpot
T getParameter(std::string const &) const
const unsigned int nTracks(const reco::Vertex &sv)
std::vector< VTX > Product
edm::EDGetTokenT< Product > token_secondaryVertex
virtual void produce(edm::Event &event, const edm::EventSetup &es) override
size_type numberOfSourceCandidatePtrs() const override
std::unique_ptr< TrackVertexArbitration< VTX > > theArbitrator
edm::EDGetTokenT< InputContainer > token_tracks
TemplatedVertexArbitrator(const edm::ParameterSet ¶ms)
edm::EDGetTokenT< reco::VertexCollection > token_primaryVertex
T const * product() const
unsigned int nTracks(float minWeight=0.5) const
Returns the number of tracks in the vertex with weight above minWeight.
bool trackFilter(const reco::TrackRef &track) const
reco::TransientTrack buildTT(edm::Handle< reco::TrackCollection > &tracks, edm::ESHandle< TransientTrackBuilder > &trackbuilder, unsigned int k)