CMS 3D CMS Logo

BscSD.cc
Go to the documentation of this file.
1 // File: BscSD.cc
3 // Date: 02.2006
4 // Description: Sensitive Detector class for Bsc
5 // Modifications:
7 
12 
15 
16 #include "G4Step.hh"
17 
18 #include <iostream>
19 
20 //-------------------------------------------------------------------
22  const SensitiveDetectorCatalog& clg,
23  edm::ParameterSet const& p,
24  const SimTrackManager* manager)
25  : TimingSD(name, clg, manager), numberingScheme(nullptr) {
26  //Parameters
27  edm::ParameterSet m_p = p.getParameter<edm::ParameterSet>("BscSD");
28  int verbn = m_p.getUntrackedParameter<int>("Verbosity");
29 
30  SetVerboseLevel(verbn);
31 
32  if (name == "BSCHits") {
33  if (verbn > 0) {
34  edm::LogVerbatim("BscSim") << "name = BSCHits and new BscNumberingSchem";
35  }
37  } else {
38  edm::LogWarning("BscSim") << "BscSD: ReadoutName " << name << " not supported";
39  }
40 }
41 
43 
44 uint32_t BscSD::setDetUnitId(const G4Step* aStep) {
45  return (numberingScheme == nullptr ? 0 : numberingScheme->getUnitID(aStep));
46 }
Log< level::Info, true > LogVerbatim
unsigned int getUnitID(const G4Step *aStep) const
T getUntrackedParameter(std::string const &, T const &) const
BscNumberingScheme * numberingScheme
Definition: BscSD.h:24
static TrackerG4SimHitNumberingScheme & numberingScheme(const GeometricDet &det)
~BscSD() override
Definition: BscSD.cc:42
Log< level::Warning, false > LogWarning
uint32_t setDetUnitId(const G4Step *) override
Definition: BscSD.cc:44
BscSD(const std::string &, const SensitiveDetectorCatalog &, edm::ParameterSet const &, const SimTrackManager *)
Definition: BscSD.cc:21