95 void G4ScoreQuantityMessenger::FilterCommands()
102 filterDir->
SetGuidance(
" Scoring filter commands.");
105 fchargedCmd->
SetGuidance(
"Charged particle filter.");
109 fneutralCmd->
SetGuidance(
"Neutral particle filter.");
112 fkinECmd =
new G4UIcommand(
"/score/filter/kineticEnergy",
this);
114 fkinECmd->
SetGuidance(
"[usage] /score/filter/kineticEnergy fname Elow Ehigh unit");
115 fkinECmd->
SetGuidance(
" fname :(String) Filter Name ");
116 fkinECmd->
SetGuidance(
" Elow :(Double) Lower edge of kinetic energy");
117 fkinECmd->
SetGuidance(
" Ehigh :(Double) Higher edge of kinetic energy");
118 fkinECmd->
SetGuidance(
" unit :(String) unit of given kinetic energy");
132 fparticleCmd =
new G4UIcommand(
"/score/filter/particle",
this);
134 fparticleCmd->
SetGuidance(
"[usage] /score/filter/particle fname p0 .. pn");
135 fparticleCmd->
SetGuidance(
" fname :(String) Filter Name ");
136 fparticleCmd->
SetGuidance(
" p0 .. pn :(String) particle names");
145 fparticleKinECmd =
new G4UIcommand(
"/score/filter/particleWithKineticEnergy",
this);
146 fparticleKinECmd->
SetGuidance(
"Particle with kinetic energy filter.");
147 fparticleKinECmd->
SetGuidance(
"[usage] /score/filter/particleWithKineticEnergy fname Elow Ehigh unit p0 .. pn");
148 fparticleKinECmd->
SetGuidance(
" fname :(String) Filter Name ");
149 fparticleKinECmd->
SetGuidance(
" Elow :(Double) Lower edge of kinetic energy");
150 fparticleKinECmd->
SetGuidance(
" Ehigh :(Double) Higher edge of kinetic energy");
151 fparticleKinECmd->
SetGuidance(
" unit :(String) unit of given kinetic energy");
152 fparticleKinECmd->
SetGuidance(
" p0 .. pn :(String) particle names");
181 delete qPassCellFluxCmd;
185 delete qnOfSecondaryCmd;
187 delete qTrackLengthCmd;
188 delete qPassCellCurrCmd;
189 delete qPassTrackLengthCmd;
190 delete qFlatSurfCurrCmd;
191 delete qFlatSurfFluxCmd;
196 delete qNofCollisionCmd;
197 delete qPopulationCmd;
198 delete qTrackCountCmd;
199 delete qTerminationCmd;
200 delete qMinKinEAtGeneCmd;
202 delete qStepCheckerCmd;
209 delete fparticleKinECmd;
220 G4cerr <<
"ERROR : No mesh is currently open. Open/create a mesh first. Command ignored." <<
G4endl;
228 if(command==qTouchCmd) {
230 }
else if(command == qGetUnitCmd ){
232 }
else if(command == qSetUnitCmd ){
234 }
else if(command== qCellChgCmd) {
240 }
else if(command== qCellFluxCmd) {
258 }
else if(command== qPassCellFluxCmd) {
276 }
else if(command==qeDepCmd) {
282 }
else if(command== qdoseDepCmd) {
300 }
else if(command== qnOfStepCmd) {
305 }
else if(command== qnOfSecondaryCmd) {
310 }
else if(command== qTrackLengthCmd) {
319 }
else if(command== qPassCellCurrCmd){
326 }
else if(command== qPassTrackLengthCmd){
332 }
else if(command== qFlatSurfCurrCmd){
338 if (
StoB(token[3]) ){
345 }
else if(command== qFlatSurfFluxCmd){
350 if (
StoB(token[3]) ){
408 }
else if(command== qNofCollisionCmd){
414 }
else if(command== qPopulationCmd){
420 }
else if(command== qTrackCountCmd){
425 }
else if(command== qTerminationCmd){
432 }
else if(command== qMinKinEAtGeneCmd){
438 }
else if(command== qStepCheckerCmd){
447 }
else if(command== fchargedCmd){
452 <<
"] : Current quantity is not set. Set or touch a quantity first." <<
G4endl;
454 }
else if(command== fneutralCmd){
459 <<
"] : Current quantity is not set. Set or touch a quantity first." <<
G4endl;
461 }
else if(command== fkinECmd){
469 <<
"] : Current quantity is not set. Set or touch a quantity first." <<
G4endl;
471 }
else if(command== fparticleKinECmd){
476 <<
"] : Current quantity is not set. Set or touch a quantity first." <<
G4endl;
478 }
else if(command==fparticleCmd) {
483 <<
"] : Current quantity is not set. Set or touch a quantity first." <<
G4endl;
499 while ( !(val = next()).isNull() ) {
500 token.push_back(val);
511 std::vector<G4String> pnames;
512 for (
G4int i = 1; i<(
G4int)token.size(); i++){
513 pnames.push_back(token[i]);
527 for (
G4int i = 4; i < (
G4int)token.size(); i++){
528 filter->
add(token[i]);
538 <<
"] : Quantity name, \"" << psname <<
"\", is already existing." <<
G4endl;