BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
Loading...
Searching...
No Matches
Public Member Functions
BDSSensitiveDetector Class Referenceabstract

Virtual class to define interface for ordered multi-sensitive detector. More...

#include <BDSSensitiveDetector.hh>

Inheritance diagram for BDSSensitiveDetector:
Inheritance graph
Collaboration diagram for BDSSensitiveDetector:
Collaboration graph

Public Member Functions

 BDSSensitiveDetector (const G4String &name)
 
virtual G4VHit * last () const =0
 
virtual G4bool ProcessHitsOrdered (G4Step *step, G4TouchableHistory *rOHist, const std::vector< G4VHit * > &hits)
 
G4bool HitOrdered (G4Step *step, const std::vector< G4VHit * > &hits)
 

Detailed Description

Virtual class to define interface for ordered multi-sensitive detector.

Author
Laurie Nevay

Definition at line 39 of file BDSSensitiveDetector.hh.

Constructor & Destructor Documentation

◆ BDSSensitiveDetector()

BDSSensitiveDetector::BDSSensitiveDetector ( const G4String &  name)

Definition at line 25 of file BDSSensitiveDetector.cc.

◆ ~BDSSensitiveDetector()

virtual BDSSensitiveDetector::~BDSSensitiveDetector ( )
inlinevirtual

Definition at line 45 of file BDSSensitiveDetector.hh.

Member Function Documentation

◆ HitOrdered()

G4bool BDSSensitiveDetector::HitOrdered ( G4Step *  step,
const std::vector< G4VHit * > &  hits 
)

Hit() is non-virtual so provide separate function here for ordered multi-sensitive detectors.

Definition at line 36 of file BDSSensitiveDetector.cc.

References ProcessHitsOrdered().

Here is the call graph for this function:

◆ last()

virtual G4VHit * BDSSensitiveDetector::last ( ) const
pure virtual

Derived class should implement method to return pointer of base class type G4VHit to the last hit. Not called back to avoid confusion with the STL back() that would return a reference. We must return a pointer here.

Implemented in BDSSDEnergyDeposition, BDSSDEnergyDepositionGlobal, BDSSDSampler, BDSSDSamplerCylinder, BDSSDSamplerLink, BDSSDSamplerSphere, BDSSDCollimator, and BDSSDThinThing.

◆ ProcessHitsOrdered()

G4bool BDSSensitiveDetector::ProcessHitsOrdered ( G4Step *  step,
G4TouchableHistory *  rOHist,
const std::vector< G4VHit * > &  hits 
)
virtual

Give the opportunity to make use of the hit generated by the previous sensitive detector in an ordered one. May be nullptr. By default don't use it and call normal ProcessHits(). Derived class may override it.

Reimplemented in BDSSDCollimator, and BDSSDThinThing.

Definition at line 29 of file BDSSensitiveDetector.cc.

Referenced by HitOrdered().

Here is the caller graph for this function:

The documentation for this class was generated from the following files: