-
Notifications
You must be signed in to change notification settings - Fork 4.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #34555 from bsunanda/Run3-gex83I
Run3-gex83I Use new SD constructions for ECAL TB and FP420
- Loading branch information
Showing
8 changed files
with
67 additions
and
19 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
33 changes: 33 additions & 0 deletions
33
SimG4CMS/EcalTestBeam/plugins/EcalTBH4BeamDetectorBuilder.cc
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,33 @@ | ||
// system include files | ||
#include <string> | ||
|
||
// user include files | ||
#include "SimG4Core/SensitiveDetector/interface/SensitiveDetectorMakerBase.h" | ||
#include "SimG4Core/Notification/interface/SimActivityRegistryEnroller.h" | ||
#include "SimG4Core/SensitiveDetector/interface/SensitiveDetectorPluginFactory.h" | ||
|
||
#include "SimG4CMS/EcalTestBeam/interface/EcalTBH4BeamSD.h" | ||
|
||
#include "FWCore/Framework/interface/EventSetup.h" | ||
#include "FWCore/Framework/interface/ConsumesCollector.h" | ||
#include "FWCore/Utilities/interface/ESGetToken.h" | ||
#include "FWCore/PluginManager/interface/ModuleDef.h" | ||
#include "FWCore/ParameterSet/interface/ParameterSet.h" | ||
|
||
class EcalTBH4BeamDetectorBuilder : public SensitiveDetectorMakerBase { | ||
public: | ||
explicit EcalTBH4BeamDetectorBuilder(const edm::ParameterSet& p, edm::ConsumesCollector cc) {} | ||
|
||
std::unique_ptr<SensitiveDetector> make(const std::string& iname, | ||
const SensitiveDetectorCatalog& clg, | ||
const edm::ParameterSet& p, | ||
const SimTrackManager* man, | ||
SimActivityRegistry& reg) const final { | ||
auto sd = std::make_unique<EcalTBH4BeamSD>(iname, clg, p, man); | ||
SimActivityRegistryEnroller::enroll(reg, sd.get()); | ||
return sd; | ||
} | ||
}; | ||
|
||
typedef EcalTBH4BeamSD EcalTBH4BeamDetector; | ||
DEFINE_SENSITIVEDETECTORBUILDER(EcalTBH4BeamDetectorBuilder, EcalTBH4BeamDetector); |
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,33 @@ | ||
// system include files | ||
#include <string> | ||
|
||
// user include files | ||
#include "SimG4Core/SensitiveDetector/interface/SensitiveDetectorMakerBase.h" | ||
#include "SimG4Core/Notification/interface/SimActivityRegistryEnroller.h" | ||
#include "SimG4Core/SensitiveDetector/interface/SensitiveDetectorPluginFactory.h" | ||
|
||
#include "SimG4CMS/FP420/interface/FP420SD.h" | ||
|
||
#include "FWCore/Framework/interface/EventSetup.h" | ||
#include "FWCore/Framework/interface/ConsumesCollector.h" | ||
#include "FWCore/Utilities/interface/ESGetToken.h" | ||
#include "FWCore/PluginManager/interface/ModuleDef.h" | ||
#include "FWCore/ParameterSet/interface/ParameterSet.h" | ||
|
||
class FP420SensitiveDetectorBuilder : public SensitiveDetectorMakerBase { | ||
public: | ||
explicit FP420SensitiveDetectorBuilder(const edm::ParameterSet& p, edm::ConsumesCollector cc) {} | ||
|
||
std::unique_ptr<SensitiveDetector> make(const std::string& iname, | ||
const SensitiveDetectorCatalog& clg, | ||
const edm::ParameterSet& p, | ||
const SimTrackManager* man, | ||
SimActivityRegistry& reg) const final { | ||
auto sd = std::make_unique<FP420SD>(iname, clg, p, man); | ||
SimActivityRegistryEnroller::enroll(reg, sd.get()); | ||
return sd; | ||
} | ||
}; | ||
|
||
typedef FP420SD FP420SensitiveDetector; | ||
DEFINE_SENSITIVEDETECTORBUILDER(FP420SensitiveDetectorBuilder, FP420SensitiveDetector); |
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 |
---|---|---|
@@ -1,10 +1,5 @@ | ||
#include "SimG4CMS/FP420/interface/FP420Test.h" | ||
#include "SimG4CMS/FP420/interface/FP420SD.h" | ||
#include "SimG4Core/SensitiveDetector/interface/SensitiveDetectorPluginFactory.h" | ||
#include "SimG4Core/Watcher/interface/SimWatcherFactory.h" | ||
#include "FWCore/PluginManager/interface/ModuleDef.h" | ||
//#include "FWCore/Framework/interface/MakerMacros.h" | ||
|
||
typedef FP420SD FP420SensitiveDetector; | ||
DEFINE_SENSITIVEDETECTOR(FP420SensitiveDetector); | ||
DEFINE_SIMWATCHER(FP420Test); //= |
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