File indexing completed on 2024-09-07 04:37:41
0001 #ifndef RecoLocalMuon_RPCRecHitProducer_h
0002 #define RecoLocalMuon_RPCRecHitProducer_h
0003
0004
0005
0006
0007
0008
0009
0010 #include "FWCore/Framework/interface/stream/EDProducer.h"
0011 #include "FWCore/Framework/interface/Event.h"
0012 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0013 #include "FWCore/Utilities/interface/InputTag.h"
0014 #include "DataFormats/RPCDigi/interface/RPCDigiCollection.h"
0015 #include "CondFormats/RPCObjects/interface/RPCMaskedStrips.h"
0016 #include "CondFormats/RPCObjects/interface/RPCDeadStrips.h"
0017 #include "CondFormats/DataRecord/interface/RPCMaskedStripsRcd.h"
0018 #include "CondFormats/DataRecord/interface/RPCDeadStripsRcd.h"
0019 #include "Geometry/RPCGeometry/interface/RPCGeometry.h"
0020 #include "Geometry/Records/interface/MuonGeometryRecord.h"
0021 #include "RPCRecHitBaseAlgo.h"
0022
0023 class RPCRecHitProducer : public edm::stream::EDProducer<> {
0024 public:
0025
0026 RPCRecHitProducer(const edm::ParameterSet& config);
0027
0028
0029 ~RPCRecHitProducer() override {}
0030
0031
0032 void beginRun(const edm::Run&, const edm::EventSetup&) override;
0033
0034
0035 void produce(edm::Event& event, const edm::EventSetup& setup) override;
0036
0037 private:
0038
0039 const edm::EDGetTokenT<RPCDigiCollection> theRPCDigiLabel;
0040
0041 edm::ESGetToken<RPCMaskedStrips, RPCMaskedStripsRcd> theReadoutMaskedStripsToken;
0042 edm::ESGetToken<RPCDeadStrips, RPCDeadStripsRcd> theReadoutDeadStripsToken;
0043 const edm::ESGetToken<RPCGeometry, MuonGeometryRecord> theRPCGeomToken;
0044
0045
0046 std::unique_ptr<RPCRecHitBaseAlgo> theAlgo;
0047
0048 std::unique_ptr<RPCMaskedStrips> theRPCMaskedStripsObj;
0049
0050
0051 std::unique_ptr<RPCDeadStrips> theRPCDeadStripsObj;
0052
0053
0054 enum class MaskSource { File, EventSetup } maskSource_, deadSource_;
0055
0056 std::vector<RPCMaskedStrips::MaskItem> MaskVec;
0057 std::vector<RPCDeadStrips::DeadItem> DeadVec;
0058 };
0059
0060 #endif