51 : fParticleName(particlename),
52 fWorld(parallelworld),
53 fImportanceConfigurator(0),
56 fWeightCutOffConfigurator(0),
58 fWeightWindowConfigurator(0),
72 if (fImportanceConfigurator)
74 delete fImportanceConfigurator;
75 fImportanceConfigurator = 0;
77 if (fWeightWindowConfigurator)
79 delete fWeightWindowConfigurator;
80 fWeightWindowConfigurator = 0;
87 if (fWeightCutOffConfigurator)
89 delete fWeightCutOffConfigurator;
90 fWeightCutOffConfigurator = 0;
98 fConfigurators.clear();
99 fIsConfigured =
false;
107 G4cout <<
"WARNING - G4GeometrySampler::IsConfigured()"
108 <<
" Some initalization exists, use ClearSampling()"
109 <<
" before a new initialization !" <<
G4endl;
143 fImportanceConfigurator =
146 G4cout <<
" creating importance configurator " <<
G4endl;
148 if (!fImportanceConfigurator)
150 G4Exception(
"G4GeometrySampler::PrepareImportanceSampling()",
152 "Failed allocation of G4ImportanceConfigurator !");
171 fWeightCutOffConfigurator =
179 if (!fWeightCutOffConfigurator)
181 G4Exception(
"G4GeometrySampler::PrepareWeightRoulett()",
183 "Failed allocation of G4WeightCutOffConfigurator !");
197 fWeightWindowConfigurator =
201 placeOfAction, paraflag);
209 fIsConfigured =
true;
217 if (fImportanceConfigurator)
219 G4cout <<
" importance configurator push_back " <<
G4endl;
220 fConfigurators.push_back(fImportanceConfigurator);
223 if (fWeightWindowConfigurator)
225 G4cout <<
" weight window configurator push_back " <<
G4endl;
226 fConfigurators.push_back(fWeightWindowConfigurator);
233 for (G4Configurators::iterator it = fConfigurators.begin();
234 it != fConfigurators.end(); it++)
244 if (fWeightCutOffConfigurator)
261 fParticleName = particlename;