k4SimGeant4
Loading...
Searching...
No Matches
GeoSvc Class Reference

#include <Detector/DetComponents/src/GeoSvc.h>

Inheritance diagram for GeoSvc:
Collaboration diagram for GeoSvc:

Public Member Functions

 GeoSvc (const std::string &name, ISvcLocator *svc)
 Default constructor.
 
virtual ~GeoSvc ()
 Destructor.
 
virtual StatusCode initialize () final
 Initialize function.
 
virtual StatusCode finalize () final
 Finalize function.
 
StatusCode buildDD4HepGeo ()
 This function generates the DD4hep geometry.
 
StatusCode buildGeant4Geo ()
 This function generates the Geant4 geometry.
 
virtual dd4hep::DetElement getDD4HepGeo () override
 
virtual dd4hep::Detector * getDetector () override
 
virtual std::string constantAsString (std::string const &name) override
 
virtual G4VUserDetectorConstruction * getGeant4Geo () override
 

Private Attributes

dd4hep::Detector * m_dd4hepgeo
 Pointer to the interface to the DD4hep geometry.
 
std::shared_ptr< G4VUserDetectorConstruction > m_geant4geo
 Pointer to the detector construction of DDG4.
 
Gaudi::Property< std::vector< std::string > > m_xmlFileNames {this, "detectors", {}, "Detector descriptions XML-files"}
 XML-files with the detector description.
 
Gaudi::Property< std::map< std::string, std::string > > m_sensitive_types {this, "sensitiveTypes", {{"tracker", "SimpleTrackerSD"}, {"calorimeter", "SimpleCalorimeterSD"}}}
 mapping of sensitive detector names
 
Gaudi::Property< bool > m_buildGeant4Geo {this, "EnableGeant4Geo", true, "If True the DD4hep geometry is converted for Geant4 Simulations"}
 Whether to create the geant4 geometry or not.
 

Constructor & Destructor Documentation

◆ GeoSvc()

GeoSvc::GeoSvc ( const std::string & name,
ISvcLocator * svc )

Default constructor.

◆ ~GeoSvc()

GeoSvc::~GeoSvc ( )
virtual

Destructor.

Member Function Documentation

◆ buildDD4HepGeo()

StatusCode GeoSvc::buildDD4HepGeo ( )

This function generates the DD4hep geometry.

◆ buildGeant4Geo()

StatusCode GeoSvc::buildGeant4Geo ( )

This function generates the Geant4 geometry.

◆ constantAsString()

std::string GeoSvc::constantAsString ( std::string const & name)
overridevirtual

◆ finalize()

StatusCode GeoSvc::finalize ( )
finalvirtual

Finalize function.

◆ getDD4HepGeo()

dd4hep::DetElement GeoSvc::getDD4HepGeo ( )
overridevirtual

◆ getDetector()

dd4hep::Detector * GeoSvc::getDetector ( )
overridevirtual

◆ getGeant4Geo()

G4VUserDetectorConstruction * GeoSvc::getGeant4Geo ( )
overridevirtual

◆ initialize()

StatusCode GeoSvc::initialize ( )
finalvirtual

Initialize function.

Member Data Documentation

◆ m_buildGeant4Geo

Gaudi::Property<bool> GeoSvc::m_buildGeant4Geo {this, "EnableGeant4Geo", true, "If True the DD4hep geometry is converted for Geant4 Simulations"}
private

Whether to create the geant4 geometry or not.

◆ m_dd4hepgeo

dd4hep::Detector* GeoSvc::m_dd4hepgeo
private

Pointer to the interface to the DD4hep geometry.

◆ m_geant4geo

std::shared_ptr<G4VUserDetectorConstruction> GeoSvc::m_geant4geo
private

Pointer to the detector construction of DDG4.

◆ m_sensitive_types

Gaudi::Property<std::map<std::string, std::string> > GeoSvc::m_sensitive_types {this, "sensitiveTypes", {{"tracker", "SimpleTrackerSD"}, {"calorimeter", "SimpleCalorimeterSD"}}}
private

mapping of sensitive detector names

◆ m_xmlFileNames

Gaudi::Property<std::vector<std::string> > GeoSvc::m_xmlFileNames {this, "detectors", {}, "Detector descriptions XML-files"}
private

XML-files with the detector description.


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