|
|
Go to the documentation of this file.
33 #include "CLHEP/Random/RandFlat.h"
36 class HepRandomEngine;
40 produces<RPCDigiCollection>();
41 produces<RPCDigitizerSimLinks>(
"RPCDigiSimLink");
48 if (!rng.isAvailable()) {
50 <<
"RPCDigitizer requires the RandomNumberGeneratorService\n"
51 "which is not present in the configuration file. You must add the service\n"
52 "in the configuration file or remove the modules that require it.";
60 geomToken = esConsumes<RPCGeometry, MuonGeometryRecord, edm::Transition::BeginRun>();
61 noiseToken = esConsumes<RPCStripNoises, RPCStripNoisesRcd, edm::Transition::BeginRun>();
62 clsToken = esConsumes<RPCClusterSize, RPCClusterSizeRcd, edm::Transition::BeginRun>();
96 CLHEP::HepRandomEngine* engine = &rng->
getEngine(
e.streamID());
98 LogDebug(
"RPCandIRPCDigiProducer") <<
"[RPCandIRPCDigiProducer::produce] got the CLHEP::HepRandomEngine engine from "
99 "the edm::Event.streamID() and edm::Service<edm::RandomNumberGenerator>";
100 LogDebug(
"RPCandIRPCDigiProducer") <<
"[RPCandIRPCDigiProducer::produce] test the CLHEP::HepRandomEngine by firing "
101 "once RandFlat ---- this must be the first time in SimMuon/RPCDigitizer";
102 LogDebug(
"RPCandIRPCDigiProducer") <<
"[RPCandIRPCDigiProducer::produce] to activate the test go in "
103 "RPCandIRPCDigiProducer.cc and uncomment the line below";
119 e.put(
std::move(RPCDigitSimLink),
"RPCDigiSimLink");
std::vector< NoiseItem > const & getVNoise() const
void doAction(MixCollection< PSimHit > &simHits, RPCDigiCollection &rpcDigis, RPCDigiSimLinks &rpcDigiSimLink, CLHEP::HepRandomEngine *)
virtual CLHEP::HepRandomEngine & getEngine(StreamID const &)=0
Use this engine in event methods.
T const * product() const
IRPCDigitizer * theIRPCDigitizer
edm::ESGetToken< RPCClusterSize, RPCClusterSizeRcd > clsToken
std::vector< ClusterSizeItem > const & getCls() const
void setRPCSimSetUp(RPCSimSetUp *simsetup)
RPCDigitizer::RPCDigiSimLinks RPCDigitizerSimLinks
void setGeometry(const RPCGeometry *geom)
sets geometry
void setRPCSimSetUp(RPCSimSetUp *simsetup)
edm::ESGetToken< RPCGeometry, MuonGeometryRecord > geomToken
void produce(edm::Event &e, const edm::EventSetup &c) override
~RPCandIRPCDigiProducer() override
void setGeometry(const RPCGeometry *geom)
sets geometry
edm::EDGetTokenT< CrossingFrame< PSimHit > > crossingFrameToken
RPCandIRPCDigiProducer(const edm::ParameterSet &ps)
RPCSimSetUp * theRPCSimSetUpRPC
const RPCGeometry * _pGeom
edm::ESGetToken< RPCStripNoises, RPCStripNoisesRcd > noiseToken
MuonDigiCollection< RPCDetId, RPCDigi > RPCDigiCollection
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
void setGeometry(const RPCGeometry *geom)
sets geometry
RPCSimSetUp * theRPCSimSetUpIRPC
T getParameter(std::string const &) const
void beginRun(const edm::Run &, const edm::EventSetup &) override
void setRPCSetUp(const std::vector< RPCStripNoises::NoiseItem > &vnoise, const std::vector< float > &vcls)
void doAction(MixCollection< PSimHit > &simHits, RPCDigiCollection &rpcDigis, RPCDigiSimLinks &rpcDigiSimLink, CLHEP::HepRandomEngine *)
std::string collection_for_XF
RPCDigitizer * theRPCDigitizer