LDMX Software
DetectorConstruction.h
1#ifndef SIMCORE_DETECTORCONSTRUCTION_H
2#define SIMCORE_DETECTORCONSTRUCTION_H
3
4//---< Geant4 >---//
5#include "G4VUserDetectorConstruction.hh"
6
7//---< Framework >---//
8#include "Framework/Configure/Parameters.h"
9
10//---< SimCore >---//
11#include "SimCore/Geo/Parser.h"
12
13// Forward declaration
14namespace simcore::geo {
15class Parser;
16}
17
18namespace simcore {
19
31class DetectorConstruction : public G4VUserDetectorConstruction {
32 public:
40 DetectorConstruction(std::shared_ptr<simcore::geo::Parser> parser,
43
47 virtual ~DetectorConstruction() = default;
48
53 G4VPhysicalVolume* Construct();
54
57 void ConstructSDandField();
58
63 std::string getDetectorName() { return parser_->getDetectorName(); }
64
65 private:
67 std::shared_ptr<simcore::geo::Parser> parser_;
68
71
74
76 enableLogging("DetectorConstruction")
77}; // DetectorConstruction
78} // namespace simcore
79
80#endif // SIMCORE_DETECTORCONSTRUCTION_H
Class encapsulating parameters for configuring a processor.
Definition Parameters.h:26
Handle to the conditions system, provided at construction to classes which require it.
Implements the Geant4 detector construction.
framework::config::Parameters parameters_
The set of parameters used to configure this class.
DetectorConstruction(std::shared_ptr< simcore::geo::Parser > parser, framework::config::Parameters &parameters, ConditionsInterface &ci)
Constructor.
G4VPhysicalVolume * Construct()
Construct the detector.
std::shared_ptr< simcore::geo::Parser > parser_
The parser used to load the detector into memory.
virtual ~DetectorConstruction()=default
Class destructor.
simcore::ConditionsInterface & conditions_interface_
interface to conditions to be passed to SDs
Dynamically loadable photonuclear models either from SimCore or external libraries implementing this ...