- Timestamp:
- Apr 6, 2009, 12:30:29 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/processes/hadronic/cross_sections/include/G4CrossSectionDataStore.hh
r819 r962 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4CrossSectionDataStore.hh,v 1.14 2009/01/24 11:54:47 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-02-ref-02 $ 28 // 29 // ------------------------------------------------------------------- 30 // 31 // GEANT4 Class header file 32 // 33 // 34 // File name: G4CrossSectionDataStore 35 // 36 // 37 // Modifications: 38 // 23.01.2009 V.Ivanchenko move constructor and destructor to source, 39 // use STL vector instead of C-array 40 // 41 26 42 // Class Description 27 43 // This is the class to which cross section data sets may be registered. … … 40 56 #include "G4Material.hh" 41 57 #include "G4VCrossSectionDataSet.hh" 58 #include <vector> 42 59 60 class G4Nucleus; 43 61 44 62 class G4CrossSectionDataStore … … 46 64 public: 47 65 48 G4CrossSectionDataStore() : 49 NDataSetList(0), verboseLevel(0) 50 {} 66 G4CrossSectionDataStore(); 51 67 52 ~G4CrossSectionDataStore() 53 {} 68 ~G4CrossSectionDataStore(); 54 69 55 56 70 G4double GetCrossSection(const G4DynamicParticle*, 71 const G4Element*, G4double aTemperature); 57 72 58 59 73 G4double GetCrossSection(const G4DynamicParticle*, 74 const G4Isotope*, G4double aTemperature); 60 75 61 62 76 G4double GetCrossSection(const G4DynamicParticle*, 77 G4double Z, G4double A, G4double aTemperature); 63 78 64 65 79 // to replace GetMicroscopicCrossSection 80 G4double GetCrossSection(const G4DynamicParticle*, const G4Material*); 66 81 67 68 SelectRandomIsotope(const G4DynamicParticle*, const G4Material*);82 //std::pair<G4double/*Z*/, G4double/*A*/> 83 // SelectRandomIsotope(const G4DynamicParticle*, const G4Material*); 69 84 70 void AddDataSet(G4VCrossSectionDataSet*); 85 G4Element* SampleZandA(const G4DynamicParticle*, const G4Material*, 86 G4Nucleus& target); 71 87 72 void BuildPhysicsTable(const G4ParticleDefinition&);88 void AddDataSet(G4VCrossSectionDataSet*); 73 89 74 void DumpPhysicsTable(const G4ParticleDefinition&);90 void BuildPhysicsTable(const G4ParticleDefinition&); 75 91 76 void SetVerboseLevel(G4int value) 77 { 78 verboseLevel = value; 79 } 92 void DumpPhysicsTable(const G4ParticleDefinition&); 80 93 81 G4int GetVerboseLevel() 82 { 83 return verboseLevel; 84 } 94 inline void SetVerboseLevel(G4int value) 95 { 96 verboseLevel = value; 97 } 98 99 inline G4int GetVerboseLevel() 100 { 101 return verboseLevel; 102 } 85 103 86 104 private: 87 105 106 G4VCrossSectionDataSet* whichDataSetInCharge(const G4DynamicParticle*, 107 const G4Element*); 88 108 89 G4VCrossSectionDataSet* whichDataSetInCharge(const G4DynamicParticle*, 90 const G4Element*); 91 92 enum { NDataSetMax = 100 }; 93 G4VCrossSectionDataSet* DataSetList[NDataSetMax]; 94 G4int NDataSetList; 95 G4int verboseLevel; 109 std::vector<G4VCrossSectionDataSet*> DataSetList; 110 G4int NDataSetList; 111 G4int verboseLevel; 96 112 }; 97 113
Note: See TracChangeset
for help on using the changeset viewer.