#include <MuonWallSD.h>
Definition at line 32 of file MuonWallSD.h.
◆ MuonWallSD()
MuonWallSD::MuonWallSD |
( |
const std::string & |
name, |
|
|
const std::string & |
hitCollectionName, |
|
|
int |
verbose |
|
) |
| |
Definition at line 27 of file MuonWallSD.cxx.
28 : G4VSensitiveDetector(
name),
35 SmartIF<StoreGateSvc>
detStore{Gaudi::svcLocator()->service(
"DetectorStore")};
38 description <<
"Constructor: DetectorStoreSvc not found!";
39 G4Exception(
"MuonWallSD",
"NoDetStore", FatalException,
description);
41 }
else if (verboseLevel >= 5) {
42 G4cout <<
"DetectorStoreSvc initialized" << G4endl;
48 G4Exception(
"MuonWallSD",
"NoTileTBIDHelper", FatalException,
description);
50 }
else if (verboseLevel >= 5) {
51 G4cout <<
"TileTBID helper retrieved" << G4endl;
◆ ~MuonWallSD()
MuonWallSD::~MuonWallSD |
( |
| ) |
|
|
default |
◆ EndOfAthenaEvent()
void MuonWallSD::EndOfAthenaEvent |
( |
| ) |
|
Definition at line 142 of file MuonWallSD.cxx.
146 if (verboseLevel >= 5) {
153 }
else if (verboseLevel >= 10) {
155 <<
" nhit=0" << G4endl;
159 if (verboseLevel >= 5) {
160 G4cout <<
"Total number of hits is " <<
m_HitColl->size() << G4endl;
◆ Initialize()
void MuonWallSD::Initialize |
( |
G4HCofThisEvent * |
| ) |
|
|
finaloverride |
Definition at line 73 of file MuonWallSD.cxx.
74 if (verboseLevel >= 5) {
75 G4cout <<
"MuonWallSD::Initialize()" << G4endl;
◆ ProcessHits()
G4bool MuonWallSD::ProcessHits |
( |
G4Step * |
aStep, |
|
|
G4TouchableHistory * |
|
|
) |
| |
|
finaloverride |
Definition at line 83 of file MuonWallSD.cxx.
84 if (verboseLevel >= 10) {
85 G4cout <<
"MuonWallSD::ProcessHits" << G4endl;
88 const G4TouchableHistory* theTouchable = (G4TouchableHistory*)(aStep->GetPreStepPoint()->GetTouchable());
89 const G4VPhysicalVolume* physVol = theTouchable->GetVolume();
90 const G4LogicalVolume* logiVol = physVol->GetLogicalVolume();
91 const G4String nameLogiVol = logiVol->GetName();
92 const G4int nScinti = physVol->GetCopyNo();
94 const G4double edep = aStep->GetTotalEnergyDeposit() * aStep->GetTrack()->GetWeight();
97 if (aStep->GetTrack()->GetDefinition()->GetPDGCharge() != 0.){
99 stepl = aStep->GetStepLength();
102 if ((edep == 0.) && (stepl == 0.)) {
109 if(nameLogiVol.find(
"MuScintillatorLayer") !=G4String::npos) {
112 }
else if(nameLogiVol.find(
"S1") !=G4String::npos) {
114 }
else if(nameLogiVol.find(
"S2") !=G4String::npos) {
116 }
else if(nameLogiVol.find(
"S3") !=G4String::npos) {
122 if (verboseLevel >= 10) {
123 G4cout << ((
m_nhits[
ind] > 0)?
"Additional hit in ":
"First hit in ")
126 <<
" time=" << aStep->GetPostStepPoint()->GetGlobalTime()
127 <<
" ene=" << edep << G4endl;
◆ StartOfAthenaEvent()
void MuonWallSD::StartOfAthenaEvent |
( |
| ) |
|
Definition at line 65 of file MuonWallSD.cxx.
66 if (verboseLevel >= 5) {
67 G4cout <<
"Initializing SD" << G4endl;
◆ m_hit
◆ m_HitColl
◆ m_id
◆ m_nhits
◆ m_tileTBID
◆ s_nCell
◆ s_nCellMu
const int MuonWallSD::s_nCellMu = 14 |
|
staticprivate |
◆ s_nCellS
const int MuonWallSD::s_nCellS = 4 |
|
staticprivate |
The documentation for this class was generated from the following files:
std::string to_string(const Identifier &id, int level=0) const
extract all fields from TileTB identifier Identifier get_all_fields ( const Identifier & id,...
int add(double energy, double time, double deltaT)
Add sub-hit to a given hit with time rounding to the center of nearest deltaT bin.