20#include <G4UIcmdWithABool.hh>
21#include <G4UIcmdWithAString.hh>
22#include <G4UIcmdWithAnInteger.hh>
23#include <G4UIdirectory.hh>
29 fTrackingAction(trackingAction),
30 fTrackingDirectory(0),
32 fNewVerboseTrackCmd(0),
33 fSaveSecondariesCmd(0),
34 fSaveDynamicChargeCmd(0)
41 fNewVerboseCmd =
new G4UIcmdWithAnInteger(
"/mcTracking/newVerbose",
this);
42 fNewVerboseCmd->SetGuidance(
"Set new verbose level (/tracking/verbose)");
43 fNewVerboseCmd->SetGuidance(
"when a track with specified track ID ");
45 "(/mcTracking/newVerboseTrack)\n starts tracking");
47 fNewVerboseCmd->SetRange(
"NewVerboseLevel >= 0 && NewVerboseLevel <= 5");
49 G4State_PreInit, G4State_Init, G4State_Idle);
52 new G4UIcmdWithAnInteger(
"/mcTracking/newVerboseTrack",
this);
54 "Set the track ID for which the new verbose level");
59 G4State_PreInit, G4State_Init, G4State_Idle);
62 new G4UIcmdWithAString(
"/mcTracking/saveSecondaries",
this);
64 "Option for saving secondaries in the stack in tracking:");
69 G4State_PreInit, G4State_Init, G4State_Idle);
72 new G4UIcmdWithABool(
"/mcTracking/saveDynamicCharge",
this);
74 "Option for saving dynamic charge of secondary particles (as TParticle "
77 "(The dynamic charge is not saved by default.)");
80 G4State_PreInit, G4State_Init, G4State_Idle);
114 if (newValue ==
"DoNotSave")
116 else if (newValue ==
"SaveInPreTrack")
118 else if (newValue ==
"SaveInStep")
Definition of the TG4Globals class and basic container types.
Definition of the TG4TrackManager class.
Definition of the TG4TrackingActionMessenger class.
Definition of the TG4TrackingAction class.
void SetTrackSaveControl(TG4TrackSaveControl control)
static TG4TrackManager * Instance()
void SetSaveDynamicCharge(G4bool saveDynamicCharge)
TG4TrackingAction * fTrackingAction
associated class
G4UIcmdWithAString * fSaveSecondariesCmd
command: saveSecondaries
virtual void SetNewValue(G4UIcommand *command, G4String string)
G4UIcmdWithABool * fSaveDynamicChargeCmd
command: saveDynamicCharge
G4UIdirectory * fTrackingDirectory
command directory
TG4TrackingActionMessenger()
Not implemented.
virtual ~TG4TrackingActionMessenger()
G4UIcmdWithAnInteger * fNewVerboseCmd
command: newVerbose
G4UIcmdWithAnInteger * fNewVerboseTrackCmd
command: newVerboseTrack
Actions at the beginnig and at the end of track.
void SetNewVerboseLevel(G4int level)
void SetNewVerboseTrackID(G4int trackID)
@ kSaveInPreTrack
save in pre-track
@ kSaveInStep
save in step