GGS(GenericGEANT4Simulation)Software
2.99.0
|
A multiplexer container for user actions. More...
#include <GGSMultiUserAction.h>
Public Member Functions | |
GGSMultiUserAction () | |
constructor. | |
~GGSMultiUserAction () | |
Destructor. More... | |
void | AddAction (std::unique_ptr< GGSUserAction > &&userAction) |
Adds a general user action. More... | |
void | AddAction (std::unique_ptr< G4UserSteppingAction > &&steppingAction) |
Adds a stepping action. More... | |
void | AddAction (std::unique_ptr< G4UserTrackingAction > &&trackingAction) |
Adds a tracking action. More... | |
void | AddAction (std::unique_ptr< G4UserEventAction > &&eventAction) |
Adds a event action. More... | |
void | AddAction (std::unique_ptr< G4UserRunAction > &&runAction) |
Adds a run action. More... | |
void | AddAction (std::unique_ptr< G4UserStackingAction > &&stackingAction) |
Adds a stacking action. More... | |
void | UserSteppingAction (const G4Step *step) |
Override of UserSteppingAction method. More... | |
void | PreUserTrackingAction (const G4Track *track) |
Override of PreUserTrackingAction method. More... | |
void | PostUserTrackingAction (const G4Track *track) |
Override of PostUserTrackingAction method. More... | |
void | BeginOfEventAction (const G4Event *event) |
Override of BeginOfEventAction method. More... | |
void | EndOfEventAction (const G4Event *event) |
Override of EndOfEventAction method. More... | |
void | BeginOfRunAction (const G4Run *run) |
Override of BeginOfRunAction method. More... | |
void | EndOfRunAction (const G4Run *run) |
Override of EndOfRunAction method. More... | |
G4ClassificationOfNewTrack | ClassifyNewTrack (const G4Track *aTrack) |
Override of ClassifyNewTrack method. More... | |
void | NewStage () |
Override of NewStage method. More... | |
void | PrepareNewEvent () |
Override of PrepareNewEvent method. More... | |
![]() | |
GGSUserAction () | |
Constructor. More... | |
virtual | ~GGSUserAction () |
Destructor. | |
G4ClassificationOfNewTrack | ClassifyNewTrack (const G4Track *) |
Override of the ClassifyNewTrack method. More... | |
A multiplexer container for user actions.
This class is intended as an actions container. User can fill it with desired actions and the class will provide the necessary interface to GEANT4 kernel calls. The main aim of this software layer is to give the user the possibility to define and use the set of actions which is most suitable for the specific simulation. The class can contain general actions inheriting from GGSUserAction (which can do something at each simulation level) as well as actions inheriting from regular GEANT4 user actions (like G4UserEventAction, which acts only at the beginning and at the end of an event). The actions are NOT guaranteed to be executed in the same order they are added to the manager. The class in current implementation owns the actions it contains.
Definition at line 32 of file GGSMultiUserAction.h.
GGSMultiUserAction::~GGSMultiUserAction | ( | ) |
Destructor.
It destroys also the actions previously added to the manager.
Definition at line 23 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::AddAction | ( | std::unique_ptr< GGSUserAction > && | userAction | ) |
Adds a general user action.
userAction | The general user action to be added to the manager. |
Definition at line 46 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::AddAction | ( | std::unique_ptr< G4UserSteppingAction > && | steppingAction | ) |
Adds a stepping action.
steppingAction | The stepping action to be added to the manager. |
Definition at line 55 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::AddAction | ( | std::unique_ptr< G4UserTrackingAction > && | trackingAction | ) |
Adds a tracking action.
trackingAction | The tracking action to be added to the manager. |
Definition at line 63 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::AddAction | ( | std::unique_ptr< G4UserEventAction > && | eventAction | ) |
Adds a event action.
eventAction | The event action to be added to the manager. |
Definition at line 72 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::AddAction | ( | std::unique_ptr< G4UserRunAction > && | runAction | ) |
Adds a run action.
runAction | The run action to be added to the manager. |
Definition at line 80 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::AddAction | ( | std::unique_ptr< G4UserStackingAction > && | stackingAction | ) |
Adds a stacking action.
stackingAction | The stacking action to be added to the manager. |
Definition at line 88 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::BeginOfEventAction | ( | const G4Event * | event | ) |
Override of BeginOfEventAction method.
This routine calls BeginOfEventAction for every general and event actions in the manager.
event | The current event. |
Definition at line 135 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::BeginOfRunAction | ( | const G4Run * | run | ) |
Override of BeginOfRunAction method.
This routine calls BeginOfRunAction for every general and run actions in the manager.
run | The current run. |
Definition at line 167 of file GGSMultiUserAction.cpp.
G4ClassificationOfNewTrack GGSMultiUserAction::ClassifyNewTrack | ( | const G4Track * | aTrack | ) |
Override of ClassifyNewTrack method.
This routine calls ClassifyNewTrack for every general actions in the manager. If no general actions are present, or if none of them reimplements ClassifyNewTrack properly, it returns the return value of G4UserStackingAction::ClassifyNewTrack. If more actions are present and the classifications are not in agreement, the default classification given by G4UserStackingAction::ClassifyNewTrack will be returned;
aTrack | The new track. |
Definition at line 193 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::EndOfEventAction | ( | const G4Event * | event | ) |
Override of EndOfEventAction method.
This routine calls EndOfEventAction for every general and event actions in the manager.
event | The current event. |
Definition at line 148 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::EndOfRunAction | ( | const G4Run * | run | ) |
Override of EndOfRunAction method.
This routine calls EndOfRunAction for every general and run actions in the manager.
run | The current run. |
Definition at line 180 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::NewStage | ( | ) |
Override of NewStage method.
This routine calls NewStage for every general and stacking actions in the manager.
Definition at line 254 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::PostUserTrackingAction | ( | const G4Track * | track | ) |
Override of PostUserTrackingAction method.
This routine calls PostUserTrackingAction for every general and tracking actions in the manager.
track | The current track. |
Definition at line 122 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::PrepareNewEvent | ( | ) |
Override of PrepareNewEvent method.
This routine calls PrepareNewEvent for every general and stacking actions in the manager.
Definition at line 262 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::PreUserTrackingAction | ( | const G4Track * | track | ) |
Override of PreUserTrackingAction method.
This routine calls PreUserTrackingAction for every general and tracking actions in the manager.
track | The current track. |
Definition at line 109 of file GGSMultiUserAction.cpp.
void GGSMultiUserAction::UserSteppingAction | ( | const G4Step * | step | ) |
Override of UserSteppingAction method.
This routine calls UserSteppingAction for every general and stepping actions in the manager.
step | The current step. |
Definition at line 96 of file GGSMultiUserAction.cpp.