Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2025-01-08 03:36:27

0001 // \class JetTracksAssociatorAtVertex JetTracksAssociatorAtVertex.cc
0002 //
0003 // Original Author:  Andrea Rizzi
0004 //         Created:  Wed Apr 12 11:12:49 CEST 2006
0005 // Accommodated for Jet Package by: Fedor Ratnikov Jul. 30, 2007
0006 //
0007 //
0008 #ifndef JetTracksAssociatorAtVertex_h
0009 #define JetTracksAssociatorAtVertex_h
0010 
0011 #include "DataFormats/Common/interface/EDProductfwd.h"
0012 #include "FWCore/Framework/interface/stream/EDProducer.h"
0013 #include "FWCore/ParameterSet/interface/ConfigurationDescriptions.h"
0014 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0015 #include "FWCore/ParameterSet/interface/ParameterSetDescription.h"
0016 #include "FWCore/Utilities/interface/InputTag.h"
0017 #include "RecoJets/JetAssociationAlgorithms/interface/JetTracksAssociationDRVertex.h"
0018 #include "RecoJets/JetAssociationAlgorithms/interface/JetTracksAssociationDRVertexAssigned.h"
0019 
0020 class JetTracksAssociatorAtVertex : public edm::stream::EDProducer<> {
0021 public:
0022   JetTracksAssociatorAtVertex(const edm::ParameterSet&);
0023   ~JetTracksAssociatorAtVertex() override = default;
0024 
0025   static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
0026   void produce(edm::Event&, const edm::EventSetup&) override;
0027 
0028 private:
0029   const edm::EDGetTokenT<edm::View<reco::Jet>> mJets;
0030   const edm::EDGetTokenT<reco::TrackCollection> mTracks;
0031 
0032   const JetTracksAssociationDRVertex mAssociator;
0033   const JetTracksAssociationDRVertexAssigned mAssociatorAssigned;
0034   const bool useAssigned;  /// if true, use the track/jet association with vertex assignment to tracks
0035   edm::EDGetTokenT<reco::VertexCollection> pvSrc;  /// if useAssigned, will read this PV collection.
0036 };
0037 
0038 #endif