-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Filename consistency and other minor changes to complete TICL->PF wor…
…kflow
- Loading branch information
Showing
6 changed files
with
45 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
#ifndef RecoHGCal_TICL_TracksterMomentumPluginBase_H__ | ||
#define RecoHGCal_TICL_TracksterMomentumPluginBase_H__ | ||
|
||
#include "DataFormats/Candidate/interface/Candidate.h" | ||
#include "DataFormats/VertexReco/interface/Vertex.h" | ||
#include "DataFormats/CaloRecHit/interface/CaloCluster.h" | ||
#include "DataFormats/HGCalReco/interface/Trackster.h" | ||
#include "FWCore/Framework/interface/ConsumesCollector.h" | ||
#include "FWCore/Framework/interface/Event.h" | ||
#include "FWCore/PluginManager/interface/PluginFactory.h" | ||
|
||
namespace ticl { | ||
class TracksterMomentumPluginBase { | ||
public: | ||
// TracksterMomentumPluginBase() {} | ||
TracksterMomentumPluginBase(const edm::ParameterSet&, edm::ConsumesCollector&& iC) {} | ||
typedef reco::Candidate::LorentzVector LorentzVector; | ||
virtual ~TracksterMomentumPluginBase(){}; | ||
virtual LorentzVector calcP4(const ticl::Trackster& trackster) const = 0; | ||
|
||
edm::Event& evt() { return *evt_; } | ||
|
||
// To be | ||
void beginEvent(edm::Event& evt) { | ||
evt_ = &evt; | ||
this->beginEvt(); | ||
} | ||
private: | ||
virtual void beginEvt() = 0; | ||
edm::Event* evt_; | ||
}; | ||
} // namespace | ||
|
||
typedef edmplugin::PluginFactory<ticl::TracksterMomentumPluginBase*(const edm::ParameterSet&, edm::ConsumesCollector&& iC)> TracksterMomentumPluginFactory; | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#include "RecoHGCal/TICL/interface/TracksterMomentumPluginBase.h" | ||
#include "FWCore/Framework/interface/MakerMacros.h" | ||
|
||
EDM_REGISTER_PLUGINFACTORY(TracksterMomentumPluginFactory, "TracksterMomentumPluginFactory"); |