Notifier class to prepend detector name to all G4 Physical Volumes Only to be used by the G4GeometryNotifierSvc.
More...
#include <PVNotifier.h>
Notifier class to prepend detector name to all G4 Physical Volumes Only to be used by the G4GeometryNotifierSvc.
Definition at line 15 of file PVNotifier.h.
◆ PVNotifier()
Definition at line 12 of file PVNotifier.cxx.
14{
15 G4PhysicalVolumeStore*
store = G4PhysicalVolumeStore::GetInstance();
16 store->SetNotifier(
this);
17}
G4GeometryNotifierSvc * m_notifierSvc
◆ NotifyDeRegistration()
| void PVNotifier::NotifyDeRegistration |
( |
| ) |
|
◆ NotifyRegistration()
| void PVNotifier::NotifyRegistration |
( |
| ) |
|
Definition at line 19 of file PVNotifier.cxx.
20{
21 G4PhysicalVolumeStore*
store = G4PhysicalVolumeStore::GetInstance();
23 G4VPhysicalVolume* lV = (*store)[
current-1];
24 std::string temp1 =
m_notifierSvc->GetCurrentDetectorName() +
"::";
25 std::string temp2 = lV->GetName().substr(0, temp1.size());
26 if (temp1 != temp2)
27 lV->SetName(temp1 + lV->GetName());
28}
◆ G4GeometryNotifierSvc
◆ m_notifierSvc
The documentation for this class was generated from the following files: