LDMX Software
|
Reads auxiliary information from GDML userinfo block. More...
#include <AuxInfoReader.h>
Public Member Functions | |
AuxInfoReader (G4GDMLParser *parser, const framework::config::Parameters &ps) | |
Class constructor. | |
virtual | ~AuxInfoReader () |
Class destructor. | |
void | readGlobalAuxInfo () |
Read the global auxiliary information from the auxinfo block. | |
void | assignAuxInfoToVolumes () |
Assign auxiliary info to volumes such as sensitive detectors. | |
ldmx::DetectorHeader * | getDetectorHeader () |
Get the detector header that was created from the userinfo block. | |
Private Member Functions | |
void | createMagneticField (const G4String &name, const G4GDMLAuxListType *auxInfoList) |
Create a magnetic field from GDML data. | |
void | createRegion (const G4String &name, const G4GDMLAuxListType *auxInfoList) |
Create a detector region from GDML data. | |
void | createVisAttributes (const G4String &name, const G4GDMLAuxListType *auxInfoList) |
Create visualization attributes from GDML data. | |
void | createDetectorHeader (const G4String &detectorVersion, const G4GDMLAuxListType *auxInfoList) |
Create the detector header from the global auxinfo. | |
Private Attributes | |
G4GDMLParser * | parser_ |
The GDML parser. | |
G4GDMLEvaluator * | eval_ |
The GDML expression evaluator. | |
ldmx::DetectorHeader * | detectorHeader_ {nullptr} |
Detector header with name and version. | |
Reads auxiliary information from GDML userinfo block.
Definition at line 30 of file AuxInfoReader.h.
simcore::geo::AuxInfoReader::AuxInfoReader | ( | G4GDMLParser * | parser, |
const framework::config::Parameters & | ps | ||
) |
Class constructor.
parser | The GDML parser. |
ps | configuration parameters |
Definition at line 28 of file AuxInfoReader.cxx.
|
virtual |
Class destructor.
Definition at line 32 of file AuxInfoReader.cxx.
References detectorHeader_, and eval_.
void simcore::geo::AuxInfoReader::assignAuxInfoToVolumes | ( | ) |
Assign auxiliary info to volumes such as sensitive detectors.
Definition at line 61 of file AuxInfoReader.cxx.
References simcore::MagneticFieldStore::getInstance(), simcore::VisAttributesStore::getInstance(), simcore::MagneticFieldStore::getMagneticField(), simcore::VisAttributesStore::getVisAttributes(), and parser_.
|
private |
Create the detector header from the global auxinfo.
detectorVersion | The aux value with the detector version. |
auxInfoList | The aux info with the detector header information. |
Definition at line 315 of file AuxInfoReader.cxx.
References detectorHeader_.
Referenced by readGlobalAuxInfo().
|
private |
Create a magnetic field from GDML data.
name | The name of the magnetic field. |
auxInfoList | The aux info defining the magnetic field. |
Definition at line 121 of file AuxInfoReader.cxx.
References simcore::MagneticFieldStore::addMagneticField(), eval_, and simcore::MagneticFieldStore::getInstance().
Referenced by readGlobalAuxInfo().
|
private |
Create a detector region from GDML data.
name | The name of the detector region. |
auxInfoList | The aux info defining the detector region. |
Definition at line 218 of file AuxInfoReader.cxx.
Referenced by readGlobalAuxInfo().
|
private |
Create visualization attributes from GDML data.
name | The name of the visualization attributes. |
auxInfoList | The aux info defining the visualization attributes. |
Definition at line 248 of file AuxInfoReader.cxx.
References simcore::VisAttributesStore::addVisAttributes(), and simcore::VisAttributesStore::getInstance().
Referenced by readGlobalAuxInfo().
|
inline |
Get the detector header that was created from the userinfo block.
Definition at line 58 of file AuxInfoReader.h.
References detectorHeader_.
void simcore::geo::AuxInfoReader::readGlobalAuxInfo | ( | ) |
Read the global auxiliary information from the auxinfo block.
Definition at line 37 of file AuxInfoReader.cxx.
References createDetectorHeader(), createMagneticField(), createRegion(), createVisAttributes(), and parser_.
|
private |
Detector header with name and version.
Definition at line 106 of file AuxInfoReader.h.
Referenced by createDetectorHeader(), getDetectorHeader(), and ~AuxInfoReader().
|
private |
The GDML expression evaluator.
Definition at line 101 of file AuxInfoReader.h.
Referenced by createMagneticField(), and ~AuxInfoReader().
|
private |
The GDML parser.
Definition at line 96 of file AuxInfoReader.h.
Referenced by assignAuxInfoToVolumes(), and readGlobalAuxInfo().