00001 #ifndef CD_NuclearInteractionEDProducer_H_ 00002 #define CD_NuclearInteractionEDProducer_H_ 00003 // -*- C++ -*- 00004 // 00005 // Package: NuclearAssociatonMapEDProducer 00006 // Class: NuclearInteractionEDProducer 00007 // 00015 // 00016 // Original Author: Vincent ROBERFROID 00017 // Created: Fri Aug 10 12:05:36 CET 2007 00018 // $Id: NuclearInteractionEDProducer.h,v 1.9 2008/04/16 12:14:04 roberfro Exp $ 00019 // 00020 // 00021 00022 00023 // system include files 00024 #include <memory> 00025 00026 // user include files 00027 #include "FWCore/Framework/interface/ESHandle.h" 00028 00029 #include "FWCore/Framework/interface/Frameworkfwd.h" 00030 #include "FWCore/Framework/interface/EDProducer.h" 00031 00032 #include "FWCore/Framework/interface/Event.h" 00033 #include "FWCore/Framework/interface/MakerMacros.h" 00034 00035 #include "FWCore/ParameterSet/interface/ParameterSet.h" 00036 00037 #include "DataFormats/TrackReco/interface/TrackFwd.h" 00038 00039 #include "MagneticField/Engine/interface/MagneticField.h" 00040 #include "MagneticField/Records/interface/IdealMagneticFieldRecord.h" 00041 #include "RecoTracker/NuclearSeedGenerator/interface/TrajectoryToSeedMap.h" 00042 00043 #include "DataFormats/VertexReco/interface/NuclearInteraction.h" 00044 00045 class NuclearVertexBuilder; 00046 class NuclearLikelihood; 00047 00048 class NuclearInteractionEDProducer : public edm::EDProducer { 00049 00050 public: 00051 typedef edm::RefVector<TrajectorySeedCollection> TrajectorySeedRefVector; 00052 00053 explicit NuclearInteractionEDProducer(const edm::ParameterSet&); 00054 ~NuclearInteractionEDProducer(); 00055 00056 private: 00057 virtual void beginJob(const edm::EventSetup&) ; 00058 virtual void produce(edm::Event&, const edm::EventSetup&); 00059 virtual void endJob(); 00060 00061 bool isInside( const reco::TrackRef& track, const TrajectorySeedRefVector& seeds); 00062 void findAdditionalSecondaryTracks( reco::NuclearInteraction& nucl, 00063 const edm::Handle<reco::TrackCollection>& additionalSecTracks); 00064 00065 // ----------member data --------------------------- 00066 edm::ParameterSet conf_; 00067 std::string primaryProducer_; 00068 std::string seedsProducer_; 00069 std::string secondaryProducer_; 00070 std::string additionalSecondaryProducer_; 00071 00072 std::auto_ptr< NuclearVertexBuilder > vertexBuilder; 00073 std::auto_ptr< NuclearLikelihood > likelihoodCalculator; 00074 00075 }; 00076 00077 void print(std::ostringstream& str, const reco::NuclearInteraction& nucl, const std::auto_ptr< NuclearVertexBuilder >& builder); 00078 #endif