MCPcopy Create free account
hub / github.com/Geant4/geant4 / AddRunDurationModel

Method AddRunDurationModel

source/visualization/management/src/G4Scene.cc:160–182  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

158}
159
160G4bool G4Scene::AddRunDurationModel (G4VModel* pModel, G4bool warn)
161{
162 std::vector<Model>::const_iterator i;
163 for (i = fRunDurationModelList.begin ();
164 i != fRunDurationModelList.end (); ++i) {
165 if (pModel -> GetGlobalDescription () ==
166 i->fpModel->GetGlobalDescription ()) break;
167 }
168 if (i != fRunDurationModelList.end ()) {
169 if (warn) {
170 G4warn << "G4Scene::AddRunDurationModel: model \""
171 << pModel -> GetGlobalDescription ()
172 << "\"\n is already in the run-duration list of scene \""
173 << fName
174 << "\"."
175 << G4endl;
176 }
177 return false;
178 }
179 fRunDurationModelList.push_back (Model(pModel));
180 CalculateExtent ();
181 return true;
182}
183
184G4bool G4Scene::AddEndOfEventModel (G4VModel* pModel, G4bool warn) {
185 std::size_t i, nModels = fEndOfEventModelList.size ();

Callers 6

GeometryHasChangedMethod · 0.80
SetNewValueMethod · 0.80
SetNewValueMethod · 0.80
SetNewValueMethod · 0.80
AddVisActionMethod · 0.80

Calls 4

ModelClass · 0.50
beginMethod · 0.45
endMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected