Skip to content

Commit

Permalink
added esConsumes to modules in L1Trigger/L1TTwinMux
Browse files Browse the repository at this point in the history
  • Loading branch information
JamminJones committed Jun 26, 2020
1 parent 4227922 commit 298ae53
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions L1Trigger/L1TTwinMux/plugins/L1TTwinMuxProducer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
#include <FWCore/Framework/interface/ConsumesCollector.h>
#include <FWCore/ParameterSet/interface/ParameterSet.h>
#include "FWCore/Framework/interface/stream/EDProducer.h"
#include "FWCore/Utilities/interface/ESGetToken.h"

#include "L1Trigger/L1TTwinMux/interface/L1TTwinMuxAlgorithm.h"

Expand All @@ -39,6 +40,7 @@ class L1TTwinMuxProducer : public edm::stream::EDProducer<> {
edm::EDGetToken m_dtdigi, m_dtthetadigi, m_rpcsource;
///Event Setup Handler
edm::ESHandle<L1TTwinMuxParams> tmParamsHandle;
edm::ESGetToken<L1TTwinMuxParams, L1TTwinMuxParamsRcd> m_tmParamsToken;
};

L1TTwinMuxProducer::L1TTwinMuxProducer(const edm::ParameterSet& pset) {
Expand All @@ -48,6 +50,7 @@ L1TTwinMuxProducer::L1TTwinMuxProducer(const edm::ParameterSet& pset) {
m_dtdigi = consumes<L1MuDTChambPhContainer>(pset.getParameter<edm::InputTag>("DTDigi_Source"));
m_dtthetadigi = consumes<L1MuDTChambThContainer>(pset.getParameter<edm::InputTag>("DTThetaDigi_Source"));
m_rpcsource = consumes<RPCDigiCollection>(pset.getParameter<edm::InputTag>("RPC_Source"));
m_tmParamsToken = esConsumes<L1TTwinMuxParams, L1TTwinMuxParamsRcd>();

produces<L1MuDTChambPhContainer>();
produces<L1MuDTChambThContainer>();
Expand All @@ -56,8 +59,7 @@ L1TTwinMuxProducer::L1TTwinMuxProducer(const edm::ParameterSet& pset) {
void L1TTwinMuxProducer::produce(edm::Event& e, const edm::EventSetup& c) {
std::unique_ptr<L1TTwinMuxAlgorithm> m_l1tma(new L1TTwinMuxAlgorithm());
///Check consistency of the paramters
const L1TTwinMuxParamsRcd& tmParamsRcd = c.get<L1TTwinMuxParamsRcd>();
tmParamsRcd.get(tmParamsHandle);
tmParamsHandle = c.getHandle(m_tmParamsToken);
const L1TTwinMuxParams& tmParams = *tmParamsHandle.product();

///Only RPC: the emulator's output consist from rpc->dy primitives only
Expand Down

0 comments on commit 298ae53

Please sign in to comment.