33 #include "CLHEP/Random/RandFlat.h" 36 class HepRandomEngine;
41 produces<RPCDigiCollection>();
42 produces<RPCDigitizerSimLinks>(
"RPCDigiSimLink");
49 if ( ! rng.isAvailable()) {
51 <<
"RPCDigitizer requires the RandomNumberGeneratorService\n" 52 "which is not present in the configuration file. You must add the service\n" 53 "in the configuration file or remove the modules that require it.";
57 crossingFrameToken = consumes<CrossingFrame<PSimHit>>(
edm::InputTag(mix_,collection_for_XF));
62 delete theRPCSimSetUp;
77 theRPCSimSetUp->setGeometry( pGeom );
81 theDigitizer->setGeometry( pGeom );
83 theDigitizer->setRPCSimSetUp( theRPCSimSetUp );
91 LogDebug (
"RPCDigiProducer")<<
"[RPCDigiProducer::produce] got the CLHEP::HepRandomEngine engine from the edm::Event.streamID() and edm::Service<edm::RandomNumberGenerator>";
92 LogDebug (
"RPCDigiProducer")<<
"[RPCDigiProducer::produce] test the CLHEP::HepRandomEngine by firing once RandFlat ---- this must be the first time in SimMuon/RPCDigitizer";
93 LogDebug (
"RPCDigiProducer")<<
"[RPCDigiProducer::produce] to activate the test go in RPCDigiProducer.cc and uncomment the line below";
103 std::unique_ptr<MixCollection<PSimHit> >
111 theDigitizer->doAction(*hits, *pDigis, *RPCDigitSimLink, engine);
T getParameter(std::string const &) const
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
bool getByToken(EDGetToken token, Handle< PROD > &result) const
RPCDigiProducer(const edm::ParameterSet &ps)
virtual CLHEP::HepRandomEngine & getEngine(StreamID const &)=0
Use this engine in event methods.
MuonDigiCollection< RPCDetId, RPCDigi > RPCDigiCollection
std::vector< NoiseItem > const & getVNoise() const
T const * product() const
void produce(edm::Event &e, const edm::EventSetup &c) override
StreamID streamID() const
void beginRun(const edm::Run &, const edm::EventSetup &) override
std::vector< ClusterSizeItem > const & getCls() const
~RPCDigiProducer() override