Belle II Software  release-05-01-25
SensitiveDetector.h
1 /**************************************************************************
2  * BASF2 (Belle Analysis Framework 2) *
3  * Copyright(C) 2010 - Belle II Collaboration *
4  * *
5  * Author: The Belle II Collaboration *
6  * Contributors: Leo Piilonen *
7  * *
8  * This software is provided "as is" without any warranty. *
9  **************************************************************************/
10 
11 #pragma once
12 
13 /* KLM headers. */
14 #include <klm/dbobjects/bklm/BKLMSimulationPar.h>
15 
16 /* Belle 2 headers. */
17 #include <framework/database/DBObjPtr.h>
18 #include <simulation/kernel/SensitiveDetectorBase.h>
19 
20 namespace Belle2 {
26  class BkgSensitiveDetector;
27 
28  namespace bklm {
29 
30  class Module;
31  class GeometryPar;
32 
35  class SensitiveDetector: public Simulation::SensitiveDetectorBase {
36 
37  public:
38 
40  explicit SensitiveDetector(const G4String& name);
41 
43  bool step(G4Step*, G4TouchableHistory*) override;
44 
46  void EndOfEvent(G4HCofThisEvent*) override
47  {
48  }
49 
50  private:
51 
53  void convertHitToRPCStrips(const CLHEP::Hep3Vector&, const Module*, int&, int&, int&, int&);
54 
56  bool m_FirstCall;
57 
59  double m_HitTimeMax;
60 
63 
66 
69 
70  };
71 
72  } // end of namespace bklm
73 
75 } // end of namespace Belle2
Belle2::bklm::SensitiveDetector::m_FirstCall
bool m_FirstCall
Flag to enforce once-only initializations in Initialize()
Definition: SensitiveDetector.h:64
Belle2::bklm::SensitiveDetector::m_GeoPar
GeometryPar * m_GeoPar
Pointer to GeometryPar singleton.
Definition: SensitiveDetector.h:73
Belle2::bklm::SensitiveDetector::m_SimPar
DBObjPtr< BKLMSimulationPar > m_SimPar
Simulation parameters (from DB)
Definition: SensitiveDetector.h:76
Belle2::BkgSensitiveDetector
The Class for BeamBackground Sensitive Detector.
Definition: BkgSensitiveDetector.h:34
Belle2::bklm::Module
Define the geometry of a BKLM module Each sector [octant] contains Modules.
Definition: Module.h:86
Belle2::bklm::GeometryPar
Provides BKLM geometry parameters for simulation, reconstruction etc (from Gearbox or DataBase)
Definition: GeometryPar.h:48
Belle2::bklm::SensitiveDetector::m_HitTimeMax
double m_HitTimeMax
maximum permissible hit time (based on overflow of LeCroy 1877 TDC)
Definition: SensitiveDetector.h:67
Belle2::DBObjPtr
Class for accessing objects in the database.
Definition: DBObjPtr.h:31
Belle2::bklm::SensitiveDetector::step
bool step(G4Step *, G4TouchableHistory *) override
Process each step in the BKLM.
Definition: SensitiveDetector.cc:71
Belle2
Abstract base class for different kinds of events.
Definition: MillepedeAlgorithm.h:19
Belle2::bklm::SensitiveDetector::convertHitToRPCStrips
void convertHitToRPCStrips(const CLHEP::Hep3Vector &, const Module *, int &, int &, int &, int &)
Find the ranges of matching RPC strips for each simulated hit.
Definition: SensitiveDetector.cc:188
Belle2::bklm::SensitiveDetector::SensitiveDetector
SensitiveDetector(const G4String &name)
Constructor.
Definition: SensitiveDetector.cc:47
Belle2::bklm::SensitiveDetector::m_BkgSensitiveDetector
BkgSensitiveDetector * m_BkgSensitiveDetector
Pointer to a sensitive-detector object used for beam-background steps.
Definition: SensitiveDetector.h:70
Belle2::PXD::SensitiveDetector
VXD::SensitiveDetector< PXDSimHit, PXDTrueHit > SensitiveDetector
The PXD Sensitive Detector class.
Definition: SensitiveDetector.h:36
Belle2::bklm::SensitiveDetector::EndOfEvent
void EndOfEvent(G4HCofThisEvent *) override
Tidy up at the end of each event.
Definition: SensitiveDetector.h:54