Geant4 11.2.2
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4ErrorPropagatorManager.hh
Go to the documentation of this file.
1//
2// ********************************************************************
3// * License and Disclaimer *
4// * *
5// * The Geant4 software is copyright of the Copyright Holders of *
6// * the Geant4 Collaboration. It is provided under the terms and *
7// * conditions of the Geant4 Software License, included in the file *
8// * LICENSE and available at http://cern.ch/geant4/license . These *
9// * include a list of copyright holders. *
10// * *
11// * Neither the authors of this software system, nor their employing *
12// * institutes,nor the agencies providing financial support for this *
13// * work make any representation or warranty, express or implied, *
14// * regarding this software system or assume any liability for its *
15// * use. Please see the license in the file LICENSE and URL above *
16// * for the full disclaimer and the limitation of liability. *
17// * *
18// * This code implementation is the result of the scientific and *
19// * technical work of the GEANT4 collaboration. *
20// * By using, copying, modifying or distributing the software (or *
21// * any work based on the software) you agree to acknowledge its *
22// * use in resulting scientific publications, and indicate your *
23// * acceptance of all terms of the Geant4 Software license. *
24// ********************************************************************
25//
26//
27//
28// Class Description:
29//
30// This is the class manager of the GEANT4e package.
31// It is the main interface for the user to define the setup and
32// start the propagation. Initializes GEANT4 for the propagation.
33
34// History:
35// - Created: Pedro Arce, February 2001
36// --------------------------------------------------------------------
37
38#ifndef G4ErrorPropagatorManager_hh
39#define G4ErrorPropagatorManager_hh
40
41#include "globals.hh"
43#include "G4ErrorPropagator.hh"
44#include "G4ApplicationState.hh"
45
48class G4ErrorTarget;
50
54class G4UserRunAction;
60class G4Track;
61
63{
64 public: // with description
66 // Initialise data to 0. Starts the G4ErrorRunManagerHelper and
67 // G4ErrorPropagationNavigator.
68
70
72 // Get only instance of G4ErrorPropagatorManager. If it does not exists,
73 // creates it
74
75 void EventTermination();
76 // Set state to G4ErrorState_Init
77
78 void RunTermination();
79 // Set state to G4ErrorState_Init and invoke
80 // G4ErrorRunManagerHelper::RunTermination()
81
82 void InitGeant4e();
83 // Initializes Geant4 and Geant4e
84
86 // Set the propagator step number to 0 and the G4ErrorState to Propagating
87
89 // Creates the G4ErrorMag_UsualEqRhs, that will control backwards tracking
90
91 G4int Propagate(G4ErrorTrajState* currentTS, const G4ErrorTarget* target,
93 // Inits track propagation, invokes G4ErrorPropagator::Propagate and
94 // terminates "event"
95
98 // Invokes G4ErrorPropagator::PropagateOneStep
99
101 // Close Geant4 geometry
102
104 // Invokes G4ErrorRunManagerHelper to construct detector and set
105 // world volume
107 // Invokes G4ErrorRunManagerHelper to set world volume
109 // Invokes G4ErrorRunManagerHelper to initialize physics
110
111 void SetUserAction(G4UserTrackingAction* userAction);
112 // Invokes G4EventManager to set a G4UserTrackingAction
113 void SetUserAction(G4UserSteppingAction* userAction);
114 // Invokes G4EventManager to set a G4UserSteppingAction
115
118 // Print Geant4e state
119
122 // Print Geant4 state
123
124 // Set and Get methods
125
127 {
128 return theG4ErrorRunManagerHelper;
129 }
130
132
134 {
135 return theG4ErrorPropagationNavigator;
136 }
137
138 G4ErrorPropagator* GetPropagator() const { return thePropagator; }
139
140 private:
141 void StartG4ErrorRunManagerHelper();
142 // Create a G4ErrorRunManagerHelper if it does not exist and set to it
143 // the G4ErrorPhysicsList
144
145 void StartNavigator();
146 // create a G4ErrorPropagationNavigator
147
148 private:
149 static G4ThreadLocal G4ErrorPropagatorManager* theG4ErrorPropagatorManager;
150
151 G4ErrorRunManagerHelper* theG4ErrorRunManagerHelper;
152
153 G4ErrorPropagator* thePropagator;
154
155 G4Mag_UsualEqRhs* theEquationOfMotion;
156
157 G4ErrorPropagationNavigator* theG4ErrorPropagationNavigator;
158};
159
160#endif
G4ApplicationState
@ G4ErrorMode_PropForwards
bool G4bool
Definition G4Types.hh:86
int G4int
Definition G4Types.hh:85
G4ErrorPropagator * GetPropagator() const
void SetUserInitialization(G4VUserDetectorConstruction *userInit)
G4int Propagate(G4ErrorTrajState *currentTS, const G4ErrorTarget *target, G4ErrorMode mode=G4ErrorMode_PropForwards)
void SetUserAction(G4UserTrackingAction *userAction)
G4int PropagateOneStep(G4ErrorTrajState *currentTS, G4ErrorMode mode=G4ErrorMode_PropForwards)
G4ErrorRunManagerHelper * GetErrorRunManagerHelper() const
static G4ErrorPropagatorManager * GetErrorPropagatorManager()
G4ErrorPropagationNavigator * GetErrorPropagationNavigator() const
#define G4ThreadLocal
Definition tls.hh:77