|
||||
File indexing completed on 2025-01-18 09:58:29
0001 // 0002 // ******************************************************************** 0003 // * License and Disclaimer * 0004 // * * 0005 // * The Geant4 software is copyright of the Copyright Holders of * 0006 // * the Geant4 Collaboration. It is provided under the terms and * 0007 // * conditions of the Geant4 Software License, included in the file * 0008 // * LICENSE and available at http://cern.ch/geant4/license . These * 0009 // * include a list of copyright holders. * 0010 // * * 0011 // * Neither the authors of this software system, nor their employing * 0012 // * institutes,nor the agencies providing financial support for this * 0013 // * work make any representation or warranty, express or implied, * 0014 // * regarding this software system or assume any liability for its * 0015 // * use. Please see the license in the file LICENSE and URL above * 0016 // * for the full disclaimer and the limitation of liability. * 0017 // * * 0018 // * This code implementation is the result of the scientific and * 0019 // * technical work of the GEANT4 collaboration. * 0020 // * By using, copying, modifying or distributing the software (or * 0021 // * any work based on the software) you agree to acknowledge its * 0022 // * use in resulting scientific publications, and indicate your * 0023 // * acceptance of all terms of the Geant4 Software license. * 0024 // ******************************************************************** 0025 // 0026 // INCL++ intra-nuclear cascade model 0027 // Alain Boudard, CEA-Saclay, France 0028 // Joseph Cugnon, University of Liege, Belgium 0029 // Jean-Christophe David, CEA-Saclay, France 0030 // Pekka Kaitaniemi, CEA-Saclay, France, and Helsinki Institute of Physics, Finland 0031 // Sylvie Leray, CEA-Saclay, France 0032 // Davide Mancusi, CEA-Saclay, France 0033 // 0034 #define INCLXX_IN_GEANT4_MODE 1 0035 0036 #include "globals.hh" 0037 0038 /** \file G4INCLXXInterfaceStore.hh 0039 * \brief Header file for the G4INCLXXInterfaceStore class 0040 * 0041 * \date 24 May 2012 0042 * \author Davide Mancusi 0043 */ 0044 0045 #ifndef G4INCLXXINTERFACESTORE_HH_ 0046 #define G4INCLXXINTERFACESTORE_HH_ 0047 0048 #include "G4INCLXXInterface.hh" 0049 #include "G4INCLCascade.hh" 0050 #include "G4INCLVersion.hh" 0051 #include "G4INCLConfig.hh" 0052 #include <list> 0053 #include <sstream> 0054 0055 class G4INCLXXInterfaceMessenger; 0056 class G4INCLXXVInterfaceTally; 0057 0058 /** \class G4INCLXXInterfaceStore 0059 * \brief Singleton class for configuring the INCL++ Geant4 interface. 0060 * 0061 * This class also contains a single cached instance of the INCL model 0062 * (\see{G4INCL::INCL}). 0063 */ 0064 class G4INCLXXInterfaceStore { 0065 public: 0066 0067 /// \brief Get the singleton instance 0068 static G4INCLXXInterfaceStore *GetInstance(); 0069 0070 /// \brief Delete the singleton instance 0071 static void DeleteInstance(); 0072 0073 /// \brief Get the cached INCL model engine 0074 G4INCL::INCL *GetINCLModel(); 0075 0076 void constructINCLXXVersionName(); 0077 0078 const std::string &getINCLXXVersionName(); 0079 0080 0081 0082 /// \brief Setter for accurateProjectile 0083 void SetAccurateProjectile(const G4bool b); 0084 0085 /// \brief Setter for the maximum cluster mass 0086 void SetMaxClusterMass(const G4int aMass); 0087 0088 /// \brief Setter for cascadeMinEnergyPerNucleon 0089 void SetCascadeMinEnergyPerNucleon(const G4double anEnergy); 0090 0091 /// \brief Setter for conservationTolerance 0092 void SetConservationTolerance(const G4double aTolerance); 0093 0094 0095 0096 0097 /** \brief Getter for accurateProjectile 0098 * 0099 * The \see{G4INCLXXInterfaceMessenger} class provides a UI command to set 0100 * this parameter. 0101 */ 0102 G4bool GetAccurateProjectile() const; 0103 0104 /** \brief Getter for cascadeMinEnergyPerNucleon 0105 * 0106 * The \see{G4INCLXXInterfaceMessenger} class provides a UI command to set 0107 * this parameter. 0108 */ 0109 G4double GetCascadeMinEnergyPerNucleon() const; 0110 0111 /// \brief Getter for theConfig 0112 G4INCL::Config &GetINCLConfig(); 0113 0114 0115 0116 0117 /// \brief Getter for theMaxProjMassINCL 0118 G4int GetMaxProjMassINCL() const; 0119 0120 0121 0122 0123 /// \brief Getter for conservationTolerance 0124 G4double GetConservationTolerance() const; 0125 0126 0127 0128 0129 /** \brief Emit a warning to G4cout 0130 * 0131 * The InterfaceStore will not emit more than maxWarnings warnings. 0132 */ 0133 void EmitWarning(const G4String &message); 0134 0135 /** \brief Emit a BIG warning to G4cout 0136 * 0137 * There is no limit on the number of BIG warnings emitted. 0138 */ 0139 void EmitBigWarning(const G4String &message) const; 0140 0141 /// \brief Getter for the interface tally 0142 G4INCLXXVInterfaceTally *GetTally() const; 0143 0144 /// \brief Setter for the interface tally 0145 void SetTally(G4INCLXXVInterfaceTally * const aTally); 0146 0147 /// \brief Set the INCL physics 0148 void SetINCLPhysics(const G4String &option); 0149 0150 /// \brief Set ABLA V3 to be the de-excitation model to be used with INCL++ 0151 void UseAblaDeExcitation(); 0152 0153 private: 0154 0155 /** \brief Private constructor 0156 * 0157 * This class is a singleton. It must be instantiated using the GetInstance 0158 * static method. 0159 */ 0160 G4INCLXXInterfaceStore(); 0161 0162 /** \brief Private destructor 0163 * 0164 * This class is a singleton. Its instance must be deleted using the 0165 * DeleteInstance static method. 0166 */ 0167 ~G4INCLXXInterfaceStore(); 0168 0169 /// \brief Delete the INCL model engine 0170 void DeleteModel(); 0171 0172 static G4ThreadLocal G4INCLXXInterfaceStore *theInstance; 0173 0174 G4INCL::Config theConfig; 0175 0176 G4bool accurateProjectile; 0177 const G4int theMaxProjMassINCL; 0178 G4double cascadeMinEnergyPerNucleon; 0179 G4double conservationTolerance; 0180 0181 G4INCLXXInterfaceMessenger *theINCLXXInterfaceMessenger; 0182 0183 G4INCL::INCL *theINCLModel; 0184 0185 G4INCLXXVInterfaceTally *theTally; 0186 0187 /// \brief Static warning counter 0188 G4int nWarnings; 0189 0190 /// \brief Maximum number of warnings 0191 const G4int maxWarnings; 0192 0193 std::string versionName; 0194 }; 0195 0196 #endif // G4INCLXXINTERFACESTORE_HH_
[ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |