Celeritas 0.6.0-129+develop.846910afa
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | List of all members
celeritas::test::LazyGeantGeoManager Class Referenceabstract

Base class for managing a persistent geometry built from Geant4. More...

#include <LazyGeantGeoManager.hh>

Inheritance diagram for celeritas::test::LazyGeantGeoManager:
Inheritance graph
[legend]

Public Types

Type aliases
using SPConstGeoI = std::shared_ptr< GeoParamsInterface const >
 
using SPConstGeantGeo = std::shared_ptr< GeantGeoParams const >
 
using SPConstVolumes = std::shared_ptr< VolumeParams const >
 

Public Member Functions

virtual std::string_view gdml_basename () const =0
 Get an identifying key for the geometry (basename, description, etc)
 
virtual SPConstGeantGeo build_geant_geo (std::string const &filename) const
 Build a Geant4 geometry.
 
virtual SPConstGeoI build_geo_from_geant (SPConstGeantGeo const &) const =0
 
virtual SPConstGeoI build_geo_from_gdml (std::string const &filename) const
 Build from a GDML path as a fallback.
 
std::string constcached_gdml_basename () const
 Access the basename of the geometry that's currently cached.
 
SPConstGeoI lazy_geo () const
 Construct a geometry for the first time.
 
SPConstGeantGeo geant_geo () const
 Access persistent geant geometry after construction.
 
SPConstVolumes volumes () const
 Access volumes from built geometry or geant4 model.
 

Static Public Member Functions

static void clear_lazy_geo ()
 Reset the secondary geometry manually.
 

Detailed Description

Base class for managing a persistent geometry built from Geant4.

Daughter classes must implement build_from_geant , and gdml_basename must return a filename prefix to a GDML file in geocel/test.

Member Function Documentation

◆ build_geant_geo()

auto celeritas::test::LazyGeantGeoManager::build_geant_geo ( std::string const filename) const
virtual

Build a Geant4 geometry.

Reimplemented in celeritas::test::SDTestBase, and celeritas::test::GeantTestBase.

◆ build_geo_from_gdml()

auto celeritas::test::LazyGeantGeoManager::build_geo_from_gdml ( std::string const filename) const
virtual

Build from a GDML path as a fallback.

Reimplemented in celeritas::test::GlobalTestBase.

◆ build_geo_from_geant()

virtual SPConstGeoI celeritas::test::LazyGeantGeoManager::build_geo_from_geant ( SPConstGeantGeo const ) const
pure virtual

◆ clear_lazy_geo()

void celeritas::test::LazyGeantGeoManager::clear_lazy_geo ( )
static

Reset the secondary geometry manually.

This is needed by AllGeoTypedTestBase, where multiple versions of the same Geant4 geometry are loaded in a single test.

◆ gdml_basename()

virtual std::string_view celeritas::test::LazyGeantGeoManager::gdml_basename ( ) const
pure virtual

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