File indexing completed on 2025-01-21 01:39:49
0001 #ifndef gen_ExternalDecayDriver_h
0002 #define gen_ExternalDecayDriver_h
0003
0004 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0005 #include "FWCore/Framework/interface/EventSetup.h"
0006 #include "FWCore/Framework/interface/ConsumesCollector.h"
0007
0008 #include <string>
0009 #include <vector>
0010
0011 namespace HepMC {
0012 class GenEvent;
0013 }
0014
0015 namespace HepMC3 {
0016 class GenEvent;
0017 }
0018
0019 namespace CLHEP {
0020 class HepRandomEngine;
0021 }
0022
0023 namespace lhef {
0024 class LHEEvent;
0025 }
0026
0027 namespace gen {
0028
0029 class EvtGenInterfaceBase;
0030 class TauolaInterfaceBase;
0031 class PhotosInterfaceBase;
0032
0033 class ExternalDecayDriver {
0034 public:
0035
0036 ExternalDecayDriver(const edm::ParameterSet&, edm::ConsumesCollector);
0037 ~ExternalDecayDriver();
0038
0039 void init(const edm::EventSetup&);
0040
0041 const std::vector<int>& operatesOnParticles() { return fPDGs; }
0042 const std::vector<std::string>& specialSettings() { return fSpecialSettings; }
0043
0044 HepMC::GenEvent* decay(HepMC::GenEvent* evt);
0045 HepMC::GenEvent* decay(HepMC::GenEvent* evt, lhef::LHEEvent* lheEvent);
0046
0047 HepMC3::GenEvent* decay(HepMC3::GenEvent* evt);
0048 HepMC3::GenEvent* decay(HepMC3::GenEvent* evt, lhef::LHEEvent* lheEvent);
0049
0050 void statistics() const;
0051
0052 void setRandomEngine(CLHEP::HepRandomEngine*);
0053 std::vector<std::string> const& sharedResources() const { return exSharedResources; }
0054
0055 private:
0056 bool fIsInitialized;
0057 std::unique_ptr<TauolaInterfaceBase> fTauolaInterface;
0058 std::unique_ptr<EvtGenInterfaceBase> fEvtGenInterface;
0059 std::unique_ptr<PhotosInterfaceBase> fPhotosInterface;
0060 std::vector<int> fPDGs;
0061 std::vector<std::string> fSpecialSettings;
0062
0063 std::vector<std::string> exSharedResources;
0064 };
0065
0066 }
0067
0068 #endif