1#ifndef _GEO_SETUP_INCLUDED
2#define _GEO_SETUP_INCLUDED
struct SETUPMODULE setup_module
struct SETUPMODULE * setup_module_ptr
struct MODULEREVISION module_r
struct MODULEREVISION * module_r_ptr
map< TString, setup_module_ptr > m_moduleEditByName
map< TString, setup_module_ptr > m_moduleEdit
map< int, module_r_ptr > m_modules_revision_table
FairField * GetMagneticField()
Get magnetic field of the current setup geometry.
double GetRefVoltage()
Get reference voltage of the magnetic field of the current setup geometry, i.e.
int GetModuleId(int dbModuleRev)
TGeoNode * ConstructRootGeometry(const char *fileName)
string GetParameterFile(string_view detector_name)
Get path to parameter file for the given detector name of the current setup.
void ClearLocalSettings()
bool OpenLocalGeoDatabase()
TString GetModuleName(int dbModuleUndex)
FairModule * CreateModule(const TString &class_name, const TString &module_name, bool isActive)
int LoadModuleToFairRunSim(int idsm, FairRunSim *fRun)
TString GetTmpFileName(const char *baseName)
int LoadSetupToGeoManager(string_view setup_tag)
Load selected geometry setup from the Local Geometry Database and create gGeoManager instance.
bool FindModuleGeometryFile(TString &file_path)
bool ParseEditFieldMap(TXMLEngine &xml, XMLNodePointer_t node)
bool LoadLocalSettings(const char *fileName)
string GetMaterialFile()
Get the material file of the current setup, which defines the media of the setup geometry.
map< int, TString > m_loadedModule
map< int, TString > m_modules_table
TString ExportModuleGeometry(const TString &file_path, const TString &module_name, const TGeoMatrix *placement, double xMove, double yMove, double zMove)
bool ParseEditSetupModule(TXMLEngine &xml, XMLNodePointer_t node)
std::pair< int, uint64_t > CheckTagOnServer(string_view setup_tag, const char *url=GEO_SERVER_HOST)
TGeoVolume * GetRootVolume(TFile *f)
int installLocalDB(string_view setup_tag, const char *url=GEO_SERVER_HOST)
unsigned long int GetServerRevision(const char *url=GEO_SERVER_HOST)
string_view GetSetupTag()
Get tag for the loaded setup.
TString GetModuleType(int dbModuleRev)
TString PrepareWritableDbDir()
setup_module_ptr FindModuleEdit(TString setup_module_tag, TString module_name, int dbModuleRev)
module_r_ptr GetModuleRevision(int dbModuleRev)
static bool exists_file(const char *name)
static int ParseGeometryTag(TString &geometry_tag, TString &local_settings)
Parse the geometry tag, which can contain the path to an XML file with a local customization of the s...
static bool IsWritableDir(const char *path)
int GetModuleIndex(TString &name)
bool ParseAddSetupModule(TXMLEngine &xml, XMLNodePointer_t node)
bool IsEqlMatrix(const char *fileName, TSQLRow *row)
~GeoSetup()
Destructor method.
unsigned long int GetLocalRevision(TString &localDbPath)
std::pair< int, string > GetTagName4PatternLocal(string_view pattern_tag, TString &localDbPath)
bool AddModuleToFairRunSim(module_r_ptr module, FairRunSim *fRun)
std::pair< int, string > GetTagName4PatternServer(string_view pattern_tag, const char *url=GEO_SERVER_HOST)
string GetLastApprovedSetupTag(string_view tag_prefix)
Get tag for the last approved setup corresponding to the pattern.
setup_module_ptr m_moduleEditAll
vector< module_r_ptr > m_moduleAdd
map< int, bool > m_modules_active
int 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 ...
const char *const GEO_SERVER_HOST