#include <G4PhysicalVolumeStore.hh>
Definition at line 57 of file G4PhysicalVolumeStore.hh.
◆ ~G4PhysicalVolumeStore()
G4PhysicalVolumeStore::~G4PhysicalVolumeStore |
( |
| ) |
|
|
virtual |
◆ G4PhysicalVolumeStore() [1/2]
◆ G4PhysicalVolumeStore() [2/2]
G4PhysicalVolumeStore::G4PhysicalVolumeStore |
( |
| ) |
|
|
protected |
◆ Clean()
void G4PhysicalVolumeStore::Clean |
( |
| ) |
|
|
static |
Definition at line 69 of file G4PhysicalVolumeStore.cc.
70{
71
72
74 {
75 G4cout <<
"WARNING - Attempt to delete the physical volume store"
76 <<
" while geometry closed !" <<
G4endl;
77 return;
78 }
79
80
81
82
83
84 locked = true;
85
86 size_t i=0;
88
89#ifdef G4GEOMETRY_VOXELDEBUG
90 G4cout <<
"Deleting Physical Volumes ... ";
91#endif
92
93 for(auto pos=store->cbegin(); pos!=store->cend(); ++pos)
94 {
97 }
98
99#ifdef G4GEOMETRY_VOXELDEBUG
100 if (store->size() < i-1)
101 {
G4cout <<
"No volumes deleted. Already deleted by user ?" <<
G4endl; }
102 else
104#endif
105
106 locked = false;
107 store->clear();
108}
G4GLOB_DLL std::ostream G4cout
static G4bool IsGeometryClosed()
static G4PhysicalVolumeStore * GetInstance()
virtual void NotifyDeRegistration()=0
Referenced by G4RunManager::ReinitializeGeometry(), and ~G4PhysicalVolumeStore().
◆ DeRegister()
◆ GetInstance()
Definition at line 180 of file G4PhysicalVolumeStore.cc.
181{
183 if (fgInstance == nullptr)
184 {
185 fgInstance = &worldStore;
186 }
187 return fgInstance;
188}
Referenced by G4AdjointCrossSurfChecker::AddanExtSurfaceOfAvolume(), G4AdjointCrossSurfChecker::AddaSphericalSurfaceWithCenterAtTheCenterOfAVolume(), Clean(), G4SPSPosDistribution::ConfineSourceToVolume(), G4AdjointPosOnPhysVolGenerator::DefinePhysicalVolume(), DeRegister(), G4GeometryWorkspace::DestroyWorkspace(), G4GDMLReadStructure::GetPhysvol(), G4tgbGeometryDumper::GetTopPhysVol(), GetVolume(), G4GeometryWorkspace::InitialisePhysicalVolumes(), Register(), G4RunManager::ReinitializeGeometry(), SetNotifier(), G4ScoringRealWorld::SetupGeometry(), G4RegionStore::SetWorldVolume(), and G4GDMLRead::StripNames().
◆ GetVolume()
Definition at line 158 of file G4PhysicalVolumeStore.cc.
159{
161 {
162 if ((*i)->GetName() ==
name) {
return *i; }
163 }
164 if (verbose)
165 {
166 std::ostringstream message;
167 message <<
"Volume NOT found in store !" <<
G4endl
168 <<
" Volume " <<
name <<
" NOT found in store !" <<
G4endl
169 << " Returning NULL pointer.";
172 }
173 return nullptr;
174}
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
const char * name(G4int ptype)
Referenced by G4GDMLReadStructure::GetPhysvol().
◆ operator=()
◆ Register()
◆ SetNotifier()
The documentation for this class was generated from the following files: