Skip to content

Commit

Permalink
Change RecoEgamma modules to one::EDAnalyzer
Browse files Browse the repository at this point in the history
This fixes deprecation warnings in the subsystem
  • Loading branch information
Dr15Jones committed Oct 27, 2022
1 parent dc1d492 commit 219def9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 15 deletions.
12 changes: 3 additions & 9 deletions RecoEgamma/EgammaElectronProducers/test/GEDValueMapAnalyzer.cc
Expand Up @@ -3,19 +3,17 @@
#include "FWCore/ParameterSet/interface/ParameterSet.h"
#include "FWCore/Framework/interface/ESHandle.h"
#include "FWCore/Framework/interface/MakerMacros.h"
#include "FWCore/Framework/interface/EDAnalyzer.h"
#include "FWCore/Framework/interface/one/EDAnalyzer.h"

#include "DataFormats/ParticleFlowCandidate/interface/PFCandidate.h"
#include "DataFormats/Common/interface/ValueMap.h"

#include <iostream>

class GEDValueMapAnalyzer : public edm::EDAnalyzer {
class GEDValueMapAnalyzer : public edm::one::EDAnalyzer<> {
public:
GEDValueMapAnalyzer(const edm::ParameterSet&);
~GEDValueMapAnalyzer();
virtual void beginRun(edm::Run const&, edm::EventSetup const&);
virtual void analyze(const edm::Event& iEvent, const edm::EventSetup& c);
void analyze(const edm::Event& iEvent, const edm::EventSetup& c) override;

private:
edm::InputTag inputTagValueMapElectrons_;
Expand All @@ -27,10 +25,6 @@ GEDValueMapAnalyzer::GEDValueMapAnalyzer(const edm::ParameterSet& iConfig) {
inputTagValueMapElectrons_ = iConfig.getParameter<edm::InputTag>("ElectronValueMap");
}

GEDValueMapAnalyzer::~GEDValueMapAnalyzer() { ; }

void GEDValueMapAnalyzer::beginRun(edm::Run const&, edm::EventSetup const&) { ; }

void GEDValueMapAnalyzer::analyze(const edm::Event& iEvent, const edm::EventSetup& c) {
edm::Handle<reco::PFCandidateCollection> pfCandidatesH;
bool found = iEvent.getByLabel(inputTagPFCandidates_, pfCandidatesH);
Expand Down
9 changes: 3 additions & 6 deletions RecoEgamma/EgammaIsolationAlgos/test/TestEgammaTowerIso.cc
@@ -1,4 +1,4 @@
#include "FWCore/Framework/interface/EDAnalyzer.h"
#include "FWCore/Framework/interface/one/EDAnalyzer.h"

#include "FWCore/Framework/interface/Event.h"
#include "FWCore/Framework/interface/MakerMacros.h"
Expand All @@ -7,16 +7,13 @@

#include "DataFormats/CaloTowers/interface/CaloTowerCollection.h"

struct TestEgammaTowerIsolation : public edm::EDAnalyzer {
struct TestEgammaTowerIsolation : public edm::one::EDAnalyzer<> {
explicit TestEgammaTowerIsolation(const edm::ParameterSet&) {}
~TestEgammaTowerIsolation() {}

// static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);

private:
virtual void beginJob() {}
virtual void analyze(const edm::Event&, const edm::EventSetup&);
virtual void endJob() {}
void analyze(const edm::Event&, const edm::EventSetup&) override;

std::string towerLabel = "towerMaker";
};
Expand Down

0 comments on commit 219def9

Please sign in to comment.