SimG4CMS
Forward
src
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
8
#include "
SimG4CMS/Forward/interface/BscSD.h
"
9
#include "
SimG4CMS/Forward/interface/BscG4Hit.h
"
10
#include "
SimG4CMS/Forward/interface/BscG4HitCollection.h
"
11
#include "
SimG4CMS/Forward/interface/BscNumberingScheme.h
"
12
13
#include "
FWCore/Framework/interface/ESHandle.h
"
14
#include "
FWCore/Framework/interface/EventSetup.h
"
15
#include "
FWCore/MessageLogger/interface/MessageLogger.h
"
16
17
#include "G4Step.hh"
18
19
#include <iostream>
20
21
#define debug
22
//-------------------------------------------------------------------
23
BscSD::BscSD
(
const
std::string
&
name
,
24
const
edm::EventSetup
& es,
25
const
SensitiveDetectorCatalog
& clg,
26
edm::ParameterSet
const
&
p
,
27
const
SimTrackManager
* manager)
28
:
TimingSD
(
name
, es, clg,
p
, manager),
numberingScheme
(nullptr) {
29
//Parameters
30
edm::ParameterSet
m_p =
p
.getParameter<
edm::ParameterSet
>(
"BscSD"
);
31
int
verbn = m_p.
getUntrackedParameter
<
int
>(
"Verbosity"
);
32
33
SetVerboseLevel(verbn);
34
35
if
(
name
==
"BSCHits"
) {
36
if
(verbn > 0) {
37
edm::LogInfo
(
"BscSim"
) <<
"name = BSCHits and new BscNumberingSchem"
;
38
}
39
numberingScheme
=
new
BscNumberingScheme
();
40
}
else
{
41
edm::LogWarning
(
"BscSim"
) <<
"BscSD: ReadoutName "
<<
name
<<
" not supported"
;
42
}
43
}
44
45
BscSD::~BscSD
() {
delete
numberingScheme
; }
46
47
uint32_t
BscSD::setDetUnitId
(
const
G4Step* aStep) {
48
return
(
numberingScheme
==
nullptr
? 0 :
numberingScheme
->
getUnitID
(aStep));
49
}
BscSD::setDetUnitId
uint32_t setDetUnitId(const G4Step *) override
Definition:
BscSD.cc:47
SimTrackManager
Definition:
SimTrackManager.h:35
BscG4Hit.h
BscSD.h
MessageLogger.h
ESHandle.h
BscG4HitCollection.h
BscNumberingScheme
Definition:
BscNumberingScheme.h:13
AlCaHLTBitMon_ParallelJobs.p
p
Definition:
AlCaHLTBitMon_ParallelJobs.py:153
edm::LogInfo
Definition:
MessageLogger.h:254
BscNumberingScheme.h
TimingSD
Definition:
TimingSD.h:29
edm::ParameterSet::getUntrackedParameter
T getUntrackedParameter(std::string const &, T const &) const
SensitiveDetectorCatalog
Definition:
SensitiveDetectorCatalog.h:10
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition:
AlCaHLTBitMon_QueryRunRegistry.py:256
edm::LogWarning
Definition:
MessageLogger.h:141
edm::ParameterSet
Definition:
ParameterSet.h:36
numberingScheme
static TrackerG4SimHitNumberingScheme & numberingScheme(const GeometricDet &det)
Definition:
TkAccumulatingSensitiveDetector.cc:39
BscNumberingScheme::getUnitID
unsigned int getUnitID(const G4Step *aStep) const
Definition:
BscNumberingScheme.cc:33
edm::EventSetup
Definition:
EventSetup.h:57
BscSD::numberingScheme
BscNumberingScheme * numberingScheme
Definition:
BscSD.h:26
BscSD::BscSD
BscSD(const std::string &, const edm::EventSetup &, const SensitiveDetectorCatalog &, edm::ParameterSet const &, const SimTrackManager *)
Definition:
BscSD.cc:23
Skims_PA_cff.name
name
Definition:
Skims_PA_cff.py:17
EventSetup.h
BscSD::~BscSD
~BscSD() override
Definition:
BscSD.cc:45
Generated for CMSSW Reference Manual by
1.8.16