| 57 | } |
| 58 | |
| 59 | void G4ParallelWorldProcessStore::SetParallelWorld(G4ParallelWorldProcess* proc, |
| 60 | const G4String& parallelWorldName) |
| 61 | { |
| 62 | for (const auto& [process, name] : *fInstance) |
| 63 | { |
| 64 | if(process == proc) |
| 65 | { |
| 66 | if(name == parallelWorldName) |
| 67 | { |
| 68 | return; // already registered |
| 69 | } |
| 70 | |
| 71 | // inconsistent ! |
| 72 | G4ExceptionDescription ED; |
| 73 | ED << "G4ParallelWorldProcess (" << proc << ") has the world volume (" << name |
| 74 | << "). It is inconsistent with (" << parallelWorldName << ")."; |
| 75 | G4Exception("G4ParallelWorldProcessStore::SetParallelWorld", "ProcScore0101", FatalException, |
| 76 | ED); |
| 77 | } |
| 78 | } |
| 79 | (*fInstance)[proc] = parallelWorldName; |
| 80 | } |
| 81 | |
| 82 | void G4ParallelWorldProcessStore::UpdateWorlds() |
| 83 | { |
no test coverage detected