00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049 #ifndef G4EmConfigurator_h
00050 #define G4EmConfigurator_h 1
00051
00052 #include "globals.hh"
00053 #include "G4VEmModel.hh"
00054 #include "G4VEmFluctuationModel.hh"
00055 #include <vector>
00056
00057
00058
00059 class G4VEnergyLossProcess;
00060 class G4VEmProcess;
00061 class G4VMultipleScattering;
00062
00063 class G4EmConfigurator
00064 {
00065 public:
00066
00067 G4EmConfigurator(G4int verboseLevel = 1);
00068
00069 ~G4EmConfigurator();
00070
00071
00072
00073
00074
00075 void SetExtraEmModel(const G4String& particleName,
00076 const G4String& processName,
00077 G4VEmModel*,
00078 const G4String& regionName = "",
00079 G4double emin = 0.0,
00080 G4double emax = DBL_MAX,
00081 G4VEmFluctuationModel* fm = 0);
00082
00083
00084
00085
00086 void AddModels();
00087
00088
00089
00090 void PrepareModels(const G4ParticleDefinition* aParticle,
00091 G4VEnergyLossProcess* p);
00092
00093 void PrepareModels(const G4ParticleDefinition* aParticle,
00094 G4VEmProcess* p);
00095
00096 void PrepareModels(const G4ParticleDefinition* aParticle,
00097 G4VMultipleScattering* p);
00098
00099 void Clear();
00100
00101 inline void SetVerbose(G4int value);
00102
00103 private:
00104
00105 G4Region* FindRegion(const G4String&);
00106
00107 void SetModelForRegion(G4VEmModel* model,
00108 G4VEmFluctuationModel* fm,
00109 G4Region* reg,
00110 const G4String& particleName,
00111 const G4String& processName,
00112 G4double emin,
00113 G4double emax);
00114
00115 G4bool UpdateModelEnergyRange(G4VEmModel* mod,
00116 G4double emin, G4double emax);
00117
00118
00119 G4EmConfigurator & operator=(const G4EmConfigurator &right);
00120 G4EmConfigurator(const G4EmConfigurator&);
00121
00122 std::vector<G4VEmModel*> models;
00123 std::vector<G4VEmFluctuationModel*> flucModels;
00124 std::vector<G4String> particles;
00125 std::vector<G4String> processes;
00126 std::vector<G4String> regions;
00127 std::vector<G4double> lowEnergy;
00128 std::vector<G4double> highEnergy;
00129
00130 G4int index;
00131 G4int verbose;
00132 };
00133
00134
00135
00136 inline void G4EmConfigurator::SetVerbose(G4int value)
00137 {
00138 verbose = value;
00139 }
00140
00141 #endif
00142
00143
00144
00145
00146
00147
00148
00149