Celeritas
0.5.0-86+4a8eea4
|
Manage a simple calorimeter sensitive detector across threads. More...
#include <GeantSimpleCalo.hh>
Public Types | |
Type aliases | |
using | SPConstParams = std::shared_ptr< SharedParams const > |
using | UPSensitiveDetector = std::unique_ptr< G4VSensitiveDetector > |
using | VecLV = std::vector< G4LogicalVolume * > |
using | VecReal = std::vector< double > |
using | EnergyUnits = units::Mev |
Public Types inherited from celeritas::OutputInterface | |
enum class | Category { input , result , system , internal , size_ } |
Output category (TODO: could replace with string/cstring?) | |
Public Member Functions | |
GeantSimpleCalo (std::string name, SPConstParams params, VecLV volumes) | |
Construct with name and logical volume pointers. | |
UPSensitiveDetector | MakeSensitiveDetector () |
Emit a new detector for the local thread and attach to the stored LVs. | |
VecLV const & | Volumes () const |
Get the list of volumes with this SD attached. | |
VecReal | CalcTotalEnergyDeposition () const |
Calculate thread-integrated energy deposition. More... | |
Output interface | |
Category of data to write | |
Category | category () const final |
Return the key in the JSON output. | |
std::string_view | label () const final |
Return the key in the JSON output. | |
void | output (JsonPimpl *) const final |
Write output to the given JSON object. | |
Manage a simple calorimeter sensitive detector across threads.
The factory should be created in DetectorConstruction or DetectorConstruction::Construct and added to the output parameters. Calling MakeSensitiveDetector
will emit a sensitive detector for the local thread and attach it to the logical volumes on the local thread.
auto celeritas::GeantSimpleCalo::CalcTotalEnergyDeposition | ( | ) | const |
Calculate thread-integrated energy deposition.
This function should only be called after all detector data has been collected.