File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1111#include " FairGeoInterface.h" // for FairGeoInterface
1212#include " FairGeoLoader.h" // for FairGeoLoader
1313#include " FairGeoNode.h" // for FairGeoNode
14- #include " FairGeoVolume .h" // for FairGeoVolume
15- #include " FairLogger .h"
14+ #include " FairGeoSet .h"
15+ #include " FairGeoVolume .h"
1616#include " FairRun.h" // for FairRun
1717#include " FairRuntimeDb.h" // for FairRuntimeDb
1818
2525#include < TRefArray.h> // for TRefArray
2626#include < TString.h> // for TString, operator!=
2727#include < TVirtualMC.h>
28+ #include < fairlogger/Logger.h>
2829#include < string>
30+ #include < type_traits>
2931#include < vector>
3032
3133class FairVolumeList ;
@@ -174,9 +176,11 @@ class FairModule : public TNamed
174176template <class T , class U >
175177void FairModule::ConstructASCIIGeometry (TString containerName)
176178{
179+ static_assert (std::is_base_of_v<FairGeoSet,T>);
180+ static_assert (std::is_base_of_v<FairParSet,U>);
181+ FairGeoSet* MGeo = new T ();
177182 FairGeoLoader* loader = FairGeoLoader::Instance ();
178183 FairGeoInterface* GeoInterface = loader->getGeoInterface ();
179- T* MGeo = new T ();
180184 MGeo->print ();
181185 MGeo->setGeomFile (GetGeometryFileName ());
182186 GeoInterface->addGeoModule (MGeo); // takes ownership!
You can’t perform that action at this time.
0 commit comments