BmnRoot
Loading...
Searching...
No Matches
GeoSetup Class Reference

#include <GeoSetup.h>

Public Member Functions

 GeoSetup ()
 
 ~GeoSetup ()
 
int LoadSetupToGeoManager (string_view setup_tag)
 
int LoadSetupToFairRunSim (string_view setupTag, const char *localSettings=nullptr)
 
FairField * GetMagneticField (double scale=0)
 
string_view GetParameterFile (string_view detector_name)
 
string_view GetLastApprovedSetupTag (string_view tag_prefix)
 
string_view GetSetupTag ()
 
 GeoSetup ()
 
 ~GeoSetup ()
 
int LoadSetupToGeoManager (string_view setup_tag)
 
int LoadSetupToFairRunSim (string_view setupTag, const char *localSettings=nullptr)
 
FairField * GetMagneticField (double scale=0)
 
string_view GetParameterFile (string_view detector_name)
 
string_view GetLastApprovedSetupTag (string_view tag_prefix)
 
string_view GetSetupTag ()
 

Detailed Description

GeoSetup class. It is used for loading necessary setup geometries from the Geometry Database.

Definition at line 39 of file GeoSetup.h.

Constructor & Destructor Documentation

◆ GeoSetup() [1/2]

GeoSetup::GeoSetup ( )
inline

Definition at line 43 of file GeoSetup.h.

◆ ~GeoSetup() [1/2]

GeoSetup::~GeoSetup ( )

Destructor method

Definition at line 275 of file GeoSetup.cxx.

◆ GeoSetup() [2/2]

GeoSetup::GeoSetup ( )
inline

Definition at line 43 of file GeoSetup.h.

◆ ~GeoSetup() [2/2]

GeoSetup::~GeoSetup ( )

Destructor method

Member Function Documentation

◆ GetLastApprovedSetupTag() [1/2]

string_view GeoSetup::GetLastApprovedSetupTag ( string_view  tag_prefix)

Get tag for the last approved setup corresponding to the pattern.

Parameters
tag_prefixThe prefix string to match against approved setup tags.
Returns
Tag of last approved setup corresponding to the prefix string.

Definition at line 55 of file GeoSetup.cxx.

◆ GetLastApprovedSetupTag() [2/2]

string_view GeoSetup::GetLastApprovedSetupTag ( string_view  tag_prefix)

Get tag for the last approved setup corresponding to the pattern.

Parameters
tag_prefixThe prefix string to match against approved setup tags.
Returns
Tag of last approved setup corresponding to the prefix string.

◆ GetMagneticField() [1/2]

FairField * GeoSetup::GetMagneticField ( double  scale = 0)

Get magnetic field of the current setup geometry.

Parameters
scalethe scale of the field. Default value is 0, which means that when created, scaling is not applied to the magnetic field.
Returns
Instance of the magnetic field class inherited from FairField. nullptr if no field

Definition at line 639 of file GeoSetup.cxx.

References BmnFieldMap::SetFileName(), and BmnFieldMap::SetScale().

◆ GetMagneticField() [2/2]

FairField * GeoSetup::GetMagneticField ( double  scale = 0)

Get magnetic field of the current setup geometry.

Parameters
scalethe scale of the field. Default value is 0, which means that when created, scaling is not applied to the magnetic field.
Returns
Instance of the magnetic field class inherited from FairField. nullptr if no field

◆ GetParameterFile() [1/2]

string_view GeoSetup::GetParameterFile ( string_view  detector_name)

Get path to parameter file for the given detector name of the current setup.

Parameters
detector_namethe name of the detector, for which the parameter file is needed.
Returns
Path to parameter file. "" if file did not set.

Definition at line 702 of file GeoSetup.cxx.

◆ GetParameterFile() [2/2]

string_view GeoSetup::GetParameterFile ( string_view  detector_name)

Get path to parameter file for the given detector name of the current setup.

Parameters
detector_namethe name of the detector, for which the parameter file is needed.
Returns
Path to parameter file. "" if file did not set.

◆ GetSetupTag() [1/2]

string_view GeoSetup::GetSetupTag ( )
inline

Get tag for the loaded setup.

Returns
The Tag of loaded setup.

Definition at line 98 of file GeoSetup.h.

◆ GetSetupTag() [2/2]

string_view GeoSetup::GetSetupTag ( )
inline

Get tag for the loaded setup.

Returns
The Tag of loaded setup.

Definition at line 98 of file GeoSetup.h.

◆ LoadSetupToFairRunSim() [1/2]

int GeoSetup::LoadSetupToFairRunSim ( string_view  setupTag,
const char *  localSettings = nullptr 
)

Load selected geometry setup from the Local or Central (defined by url) Geometry Database and add it to the FairRunSim instance. Use for Simulation

Parameters
setupTagthe name of the setup tag.
localSettingspath to local setting file that can disable or move some detector in selected geometry.
Returns
0, if the setup is loaded. Error code, if the setup is not loaded.

Definition at line 424 of file GeoSetup.cxx.

References GEO_SERVER_HOST.

◆ LoadSetupToFairRunSim() [2/2]

int GeoSetup::LoadSetupToFairRunSim ( string_view  setupTag,
const char *  localSettings = nullptr 
)

Load selected geometry setup from the Local or Central (defined by url) Geometry Database and add it to the FairRunSim instance. Use for Simulation

Parameters
setupTagthe name of the setup tag.
localSettingspath to local setting file that can disable or move some detector in selected geometry.
Returns
0, if the setup is loaded. Error code, if the setup is not loaded.

◆ LoadSetupToGeoManager() [1/2]

int GeoSetup::LoadSetupToGeoManager ( string_view  setup_tag)

Load selected geometry setup from the Local Geometry Database and create gGeoManager instance. Use for Reconstruction and Analysis

Parameters
setupTagthe name of the setup tag.
Returns
0, if the setup is loaded. Error code, if the setup is not loaded.

Definition at line 314 of file GeoSetup.cxx.

References GEO_SERVER_HOST.

◆ LoadSetupToGeoManager() [2/2]

int GeoSetup::LoadSetupToGeoManager ( string_view  setup_tag)

Load selected geometry setup from the Local Geometry Database and create gGeoManager instance. Use for Reconstruction and Analysis

Parameters
setupTagthe name of the setup tag.
Returns
0, if the setup is loaded. Error code, if the setup is not loaded.

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