Geant4-11
G4PhysicsListHelper.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// G4PhysicsListHelper
27//
28// Class description:
29//
30// Helper class for physics lists, to register processes according
31// to the ordering parameter table. This class is a singleton.
32
33// Author: H.Kurashige, 29 April 2011
34// --------------------------------------------------------------------
35#ifndef G4PhysicsListHelper_hh
36#define G4PhysicsListHelper_hh 1
37
38#include <vector>
39
40#include "G4ios.hh"
41#include "globals.hh"
42
44#include "G4ParticleTable.hh"
47
48class G4VProcess;
49
51{
53
54 public:
55
57 // Returns the pointer to the physics list helper
58
60 // Registers a process to the particle type according to the ordering
61 // parameter table. Returns 'true' if process is successfully registered.
62
63 void AddTransportation();
64 // User must invoke this method in his ConstructProcess() implementation
65 // in order to enable particle transportation.
66
67 void UseCoupledTransportation(G4bool vl = true);
68 // Set flag for using G4CoupledTransportation.
69
72 // Change the thresholds for killing looping tracks in transportation.
73
74 void CheckParticleList() const;
75 // Check consistencies of list of particles.
76
77 void DumpOrdingParameterTable(G4int subType = -1) const;
78 // Dump OrdingParameterTable.
79
81
82 void SetVerboseLevel(G4int value);
83 G4int GetVerboseLevel() const;
84 // set/get controle flag for output message
85 // 0: Silent
86 // 1: Warning message
87 // 2: More
88
89 private:
90
93 // Hidden constructor and destructor.
94
97
98 private:
99
100 using G4OrdParamTable = std::vector<G4PhysicsListOrderingParameter>;
101
103
106 // The particle table has the complete List of existing particle types.
107
109 G4int theLooperThresholds = 1; // 0 = Low, 1 = default, 2 = high
111
113
117};
118
119// Inline methods implementations
120
122{
124}
125
127{
128 verboseLevel = value;
129}
130
132{
133 return verboseLevel;
134}
135
136#endif
bool G4bool
Definition: G4Types.hh:86
int G4int
Definition: G4Types.hh:85
G4bool RegisterProcess(G4VProcess *process, G4ParticleDefinition *particle)
G4VProcess * theTransportationProcess
void UseCoupledTransportation(G4bool vl=true)
static G4ThreadLocal G4PhysicsListHelper * pPLHelper
static G4PhysicsListHelper * GetPhysicsListHelper()
G4ParticleTable::G4PTblDicIterator * aParticleIterator
void DumpOrdingParameterTable(G4int subType=-1) const
std::vector< G4PhysicsListOrderingParameter > G4OrdParamTable
G4ParticleTable * theParticleTable
G4PhysicsListOrderingParameter GetOrdingParameter(G4int subType) const
void SetVerboseLevel(G4int value)
G4OrdParamTable * theTable
#define G4ThreadLocal
Definition: tls.hh:77