Geant4-11
Public Member Functions | Static Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes | Static Protected Attributes
G4VPhysicsConstructor Class Referenceabstract

#include <G4VPhysicsConstructor.hh>

Inheritance diagram for G4VPhysicsConstructor:
G4ChargeExchangePhysics G4DecayPhysics G4EmDNAChemistry G4EmDNAChemistry_option1 G4EmDNAChemistry_option2 G4EmDNAChemistry_option3 G4EmDNAPhysics G4EmDNAPhysicsActivator G4EmDNAPhysics_option1 G4EmDNAPhysics_option2 G4EmDNAPhysics_option3 G4EmDNAPhysics_option4 G4EmDNAPhysics_option5 G4EmDNAPhysics_option6 G4EmDNAPhysics_option7 G4EmDNAPhysics_option8 G4EmDNAPhysics_stationary_option2 G4EmDNAPhysics_stationary_option4 G4EmDNAPhysics_stationary_option6 G4EmExtraPhysics G4EmLivermorePhysics G4EmLowEPPhysics G4EmPenelopePhysics G4EmStandardPhysics G4EmStandardPhysicsGS G4EmStandardPhysicsSS G4EmStandardPhysicsWVI G4EmStandardPhysics_option1 G4EmStandardPhysics_option2 G4EmStandardPhysics_option3 G4EmStandardPhysics_option4 G4FastSimulationPhysics G4GenericBiasingPhysics G4HadronElasticPhysics G4HadronPhysicsFTFP_BERT G4HadronPhysicsQGSP_BERT G4HadronPhysicsQGSP_BIC G4ImportanceBiasing G4IonElasticPhysics G4IonINCLXXPhysics G4IonPhysics G4IonPhysicsPHP G4IonQMDPhysics G4MuonicAtomDecayPhysics G4NeutronCrossSectionXS G4NeutronTrackingCut G4OpticalPhysics G4ParallelWorldPhysics G4RadioactiveDecayPhysics G4SpinDecayPhysics G4StepLimiterPhysics G4StoppingPhysics G4StoppingPhysicsFritiofWithBinaryCascade G4UnknownDecayPhysics G4VHadronPhysics G4WeightWindowBiasing Particles PhysListEmStandard PhysicsListEMstd pyG4VPhysicsConstructor::CB_G4VPhysicsConstructor

Public Member Functions

virtual void ConstructParticle ()=0
 
virtual void ConstructProcess ()=0
 
 G4VPhysicsConstructor (const G4String &="")
 
 G4VPhysicsConstructor (const G4String &name, G4int physics_type)
 
G4int GetInstanceID () const
 
const G4StringGetPhysicsName () const
 
G4int GetPhysicsType () const
 
G4int GetVerboseLevel () const
 
void SetPhysicsName (const G4String &="")
 
void SetPhysicsType (G4int)
 
void SetVerboseLevel (G4int value)
 
virtual void TerminateWorker ()
 
virtual ~G4VPhysicsConstructor ()
 

Static Public Member Functions

static const G4VPCManagerGetSubInstanceManager ()
 

Protected Types

using PhysicsBuilder_V = G4VPCData::PhysicsBuilders_V
 

Protected Member Functions

void AddBuilder (G4PhysicsBuilderInterface *bld)
 
PhysicsBuilder_V GetBuilders () const
 
G4ParticleTable::G4PTblDicIteratorGetParticleIterator () const
 
G4bool RegisterProcess (G4VProcess *process, G4ParticleDefinition *particle)
 

Protected Attributes

G4int g4vpcInstanceID = 0
 
G4String namePhysics = ""
 
G4ParticleTabletheParticleTable = nullptr
 
G4int typePhysics = 0
 
G4int verboseLevel = 0
 

Static Protected Attributes

static G4RUN_DLL G4VPCManager subInstanceManager
 

Detailed Description

Definition at line 108 of file G4VPhysicsConstructor.hh.

Member Typedef Documentation

◆ PhysicsBuilder_V

Definition at line 149 of file G4VPhysicsConstructor.hh.

Constructor & Destructor Documentation

◆ G4VPhysicsConstructor() [1/2]

G4VPhysicsConstructor::G4VPhysicsConstructor ( const G4String name = "")

◆ G4VPhysicsConstructor() [2/2]

G4VPhysicsConstructor::G4VPhysicsConstructor ( const G4String name,
G4int  physics_type 
)

Definition at line 57 of file G4VPhysicsConstructor.cc.

59 , typePhysics(type)
60{
62 // pointer to the particle table
64 // aParticleIterator = theParticleTable->GetIterator();
65
66 if(type < 0)
67 typePhysics = 0;
68}

References G4VUPLSplitter< T >::CreateSubInstance(), g4vpcInstanceID, G4ParticleTable::GetParticleTable(), subInstanceManager, theParticleTable, and typePhysics.

◆ ~G4VPhysicsConstructor()

G4VPhysicsConstructor::~G4VPhysicsConstructor ( )
virtual

Definition at line 71 of file G4VPhysicsConstructor.cc.

72{
73 // Master/Sequential needs to cleanup too
75}

References TerminateWorker().

Member Function Documentation

◆ AddBuilder()

void G4VPhysicsConstructor::AddBuilder ( G4PhysicsBuilderInterface bld)
protected

◆ ConstructParticle()

virtual void G4VPhysicsConstructor::ConstructParticle ( )
pure virtual

Implemented in PhysListEmStandard, pyG4VPhysicsConstructor::CB_G4VPhysicsConstructor, PhysicsListEMstd, Particles, PhysicsListEMstd, G4NeutronCrossSectionXS, G4EmDNAChemistry, G4EmDNAChemistry_option1, G4EmDNAChemistry_option3, G4EmDNAPhysics_option1, G4EmDNAPhysics_option2, G4EmDNAPhysics_option3, G4EmDNAPhysics_option4, G4EmDNAPhysics_option5, G4EmDNAPhysics_option6, G4EmDNAPhysics_option7, G4EmDNAPhysics_option8, G4EmDNAPhysics_stationary_option2, G4EmDNAPhysics_stationary_option4, G4EmDNAPhysics_stationary_option6, G4EmExtraPhysics, G4FastSimulationPhysics, G4GenericBiasingPhysics, G4ImportanceBiasing, G4NeutronTrackingCut, G4ParallelWorldPhysics, G4StepLimiterPhysics, G4WeightWindowBiasing, G4DecayPhysics, G4MuonicAtomDecayPhysics, G4RadioactiveDecayPhysics, G4SpinDecayPhysics, G4UnknownDecayPhysics, G4EmDNAChemistry_option2, G4EmDNAPhysics, G4EmDNAPhysicsActivator, G4EmLivermorePhysics, G4EmLowEPPhysics, G4EmPenelopePhysics, G4EmStandardPhysics, G4EmStandardPhysics_option1, G4EmStandardPhysics_option2, G4EmStandardPhysics_option3, G4EmStandardPhysics_option4, G4EmStandardPhysicsGS, G4EmStandardPhysicsSS, G4EmStandardPhysicsWVI, G4OpticalPhysics, G4ChargeExchangePhysics, G4HadronElasticPhysics, G4IonElasticPhysics, G4HadronPhysicsFTFP_BERT, G4HadronPhysicsQGSP_BERT, G4HadronPhysicsQGSP_BIC, G4VHadronPhysics, G4IonINCLXXPhysics, G4IonPhysics, G4IonPhysicsPHP, G4IonQMDPhysics, G4StoppingPhysics, and G4StoppingPhysicsFritiofWithBinaryCascade.

Referenced by export_G4VPhysicsConstructor().

◆ ConstructProcess()

virtual void G4VPhysicsConstructor::ConstructProcess ( )
pure virtual

Implemented in PhysListEmStandard, pyG4VPhysicsConstructor::CB_G4VPhysicsConstructor, PhysicsListEMstd, Particles, PhysicsListEMstd, G4NeutronCrossSectionXS, G4EmDNAChemistry, G4EmDNAChemistry_option1, G4EmDNAChemistry_option3, G4EmDNAPhysics_option1, G4EmDNAPhysics_option2, G4EmDNAPhysics_option3, G4EmDNAPhysics_option4, G4EmDNAPhysics_option5, G4EmDNAPhysics_option6, G4EmDNAPhysics_option7, G4EmDNAPhysics_option8, G4EmDNAPhysics_stationary_option2, G4EmDNAPhysics_stationary_option4, G4EmDNAPhysics_stationary_option6, G4EmExtraPhysics, G4FastSimulationPhysics, G4GenericBiasingPhysics, G4ImportanceBiasing, G4NeutronTrackingCut, G4ParallelWorldPhysics, G4StepLimiterPhysics, G4WeightWindowBiasing, G4HadronElasticPhysicsHP, G4HadronElasticPhysicsLEND, G4HadronElasticPhysicsPHP, G4HadronElasticPhysicsXS, G4DecayPhysics, G4MuonicAtomDecayPhysics, G4RadioactiveDecayPhysics, G4SpinDecayPhysics, G4UnknownDecayPhysics, G4EmDNAChemistry_option2, G4EmDNAPhysics, G4EmDNAPhysics_stationary, G4EmDNAPhysicsActivator, G4EmLivermorePhysics, G4EmLowEPPhysics, G4EmPenelopePhysics, G4EmStandardPhysics, G4EmStandardPhysics_option1, G4EmStandardPhysics_option2, G4EmStandardPhysics_option3, G4EmStandardPhysics_option4, G4EmStandardPhysicsGS, G4EmStandardPhysicsSS, G4EmStandardPhysicsWVI, G4OpticalPhysics, G4ChargeExchangePhysics, G4HadronDElasticPhysics, G4HadronElasticPhysics, G4HadronHElasticPhysics, G4IonElasticPhysics, G4ThermalNeutrons, G4HadronInelasticQBBC, G4HadronPhysicsFTFP_BERT, G4HadronPhysicsFTFP_BERT_ATL, G4HadronPhysicsFTFQGSP_BERT, G4HadronPhysicsINCLXX, G4HadronPhysicsNuBeam, G4HadronPhysicsQGSP_BERT, G4HadronPhysicsQGSP_BIC, G4HadronPhysicsShielding, G4IonINCLXXPhysics, G4IonPhysics, G4IonPhysicsPHP, G4IonQMDPhysics, G4StoppingPhysics, and G4StoppingPhysicsFritiofWithBinaryCascade.

Referenced by PhysicsList::ConstructProcess(), and export_G4VPhysicsConstructor().

◆ GetBuilders()

G4VPhysicsConstructor::PhysicsBuilder_V G4VPhysicsConstructor::GetBuilders ( ) const
protected

Definition at line 86 of file G4VPhysicsConstructor.cc.

87{
88 const auto& tls = *((subInstanceManager.offset[g4vpcInstanceID])._builders);
89 PhysicsBuilder_V copy(tls.size());
90 G4int i = 0;
91 for(const auto& el : tls)
92 {
93 copy[i++] = el;
94 }
95 return copy;
96}
int G4int
Definition: G4Types.hh:85
G4VPCData::PhysicsBuilders_V PhysicsBuilder_V
void copy(G4double dst[], const G4double src[], size_t size=G4FieldTrack::ncompSVEC)
Definition: G4FieldUtils.cc:98

References field_utils::copy(), g4vpcInstanceID, G4VUPLSplitter< T >::offset, and subInstanceManager.

◆ GetInstanceID()

G4int G4VPhysicsConstructor::GetInstanceID ( ) const
inline

◆ GetParticleIterator()

G4ParticleTable::G4PTblDicIterator * G4VPhysicsConstructor::GetParticleIterator ( ) const
protected

◆ GetPhysicsName()

const G4String & G4VPhysicsConstructor::GetPhysicsName ( ) const
inline

Definition at line 191 of file G4VPhysicsConstructor.hh.

192{
193 return namePhysics;
194}

References namePhysics.

Referenced by G4EmDNAPhysics_option1::ConstructProcess(), G4EmDNAPhysics_option2::ConstructProcess(), G4EmDNAPhysics_option3::ConstructProcess(), G4EmDNAPhysics_option4::ConstructProcess(), G4EmDNAPhysics_option5::ConstructProcess(), G4EmDNAPhysics_option6::ConstructProcess(), G4EmDNAPhysics_option7::ConstructProcess(), G4EmDNAPhysics_option8::ConstructProcess(), G4EmDNAPhysics_stationary_option2::ConstructProcess(), G4EmDNAPhysics_stationary_option4::ConstructProcess(), G4EmDNAPhysics_stationary_option6::ConstructProcess(), G4EmDNAPhysics::ConstructProcess(), G4EmDNAPhysics_stationary::ConstructProcess(), G4EmLivermorePhysics::ConstructProcess(), G4EmLowEPPhysics::ConstructProcess(), G4EmPenelopePhysics::ConstructProcess(), G4EmStandardPhysics::ConstructProcess(), G4EmStandardPhysics_option1::ConstructProcess(), G4EmStandardPhysics_option2::ConstructProcess(), G4EmStandardPhysics_option3::ConstructProcess(), G4EmStandardPhysics_option4::ConstructProcess(), G4EmStandardPhysicsGS::ConstructProcess(), G4EmStandardPhysicsSS::ConstructProcess(), G4EmStandardPhysicsWVI::ConstructProcess(), G4ThermalNeutrons::ConstructProcess(), G4HadronPhysicsFTFP_BERT::DumpBanner(), G4HadronPhysicsQGSP_BERT::DumpBanner(), export_G4VPhysicsConstructor(), G4HadronDElasticPhysics::G4HadronDElasticPhysics(), G4HadronElasticPhysics::G4HadronElasticPhysics(), G4HadronElasticPhysicsHP::G4HadronElasticPhysicsHP(), G4HadronElasticPhysicsLEND::G4HadronElasticPhysicsLEND(), G4HadronElasticPhysicsPHP::G4HadronElasticPhysicsPHP(), G4HadronElasticPhysicsXS::G4HadronElasticPhysicsXS(), G4HadronHElasticPhysics::G4HadronHElasticPhysics(), G4IonElasticPhysics::G4IonElasticPhysics(), G4VModularPhysicsList::RegisterPhysics(), and G4VModularPhysicsList::ReplacePhysics().

◆ GetPhysicsType()

G4int G4VPhysicsConstructor::GetPhysicsType ( ) const
inline

Definition at line 201 of file G4VPhysicsConstructor.hh.

202{
203 return typePhysics;
204}

References typePhysics.

Referenced by G4VModularPhysicsList::RegisterPhysics(), and G4VModularPhysicsList::ReplacePhysics().

◆ GetSubInstanceManager()

const G4VPCManager & G4VPhysicsConstructor::GetSubInstanceManager ( )
inlinestatic

Definition at line 213 of file G4VPhysicsConstructor.hh.

214{
215 return subInstanceManager;
216}

References subInstanceManager.

Referenced by G4PhysicsListWorkspace::G4PhysicsListWorkspace().

◆ GetVerboseLevel()

G4int G4VPhysicsConstructor::GetVerboseLevel ( ) const
inline

◆ RegisterProcess()

G4bool G4VPhysicsConstructor::RegisterProcess ( G4VProcess process,
G4ParticleDefinition particle 
)
inlineprotected

◆ SetPhysicsName()

void G4VPhysicsConstructor::SetPhysicsName ( const G4String name = "")
inline

Definition at line 186 of file G4VPhysicsConstructor.hh.

187{
189}

References G4InuclParticleNames::name(), and namePhysics.

Referenced by export_G4VPhysicsConstructor().

◆ SetPhysicsType()

void G4VPhysicsConstructor::SetPhysicsType ( G4int  val)
inline

Definition at line 196 of file G4VPhysicsConstructor.hh.

197{
198 if(val > 0) { typePhysics = val; }
199}

References typePhysics.

Referenced by G4DecayPhysics::G4DecayPhysics(), G4EmDNAPhysics::G4EmDNAPhysics(), G4EmDNAPhysics_option1::G4EmDNAPhysics_option1(), G4EmDNAPhysics_option2::G4EmDNAPhysics_option2(), G4EmDNAPhysics_option3::G4EmDNAPhysics_option3(), G4EmDNAPhysics_option4::G4EmDNAPhysics_option4(), G4EmDNAPhysics_option5::G4EmDNAPhysics_option5(), G4EmDNAPhysics_option6::G4EmDNAPhysics_option6(), G4EmDNAPhysics_option7::G4EmDNAPhysics_option7(), G4EmDNAPhysics_option8::G4EmDNAPhysics_option8(), G4EmDNAPhysics_stationary_option2::G4EmDNAPhysics_stationary_option2(), G4EmDNAPhysics_stationary_option4::G4EmDNAPhysics_stationary_option4(), G4EmDNAPhysics_stationary_option6::G4EmDNAPhysics_stationary_option6(), G4EmExtraPhysics::G4EmExtraPhysics(), G4EmLivermorePhysics::G4EmLivermorePhysics(), G4EmLowEPPhysics::G4EmLowEPPhysics(), G4EmPenelopePhysics::G4EmPenelopePhysics(), G4EmStandardPhysics::G4EmStandardPhysics(), G4EmStandardPhysics_option1::G4EmStandardPhysics_option1(), G4EmStandardPhysics_option2::G4EmStandardPhysics_option2(), G4EmStandardPhysics_option3::G4EmStandardPhysics_option3(), G4EmStandardPhysics_option4::G4EmStandardPhysics_option4(), G4EmStandardPhysicsGS::G4EmStandardPhysicsGS(), G4EmStandardPhysicsSS::G4EmStandardPhysicsSS(), G4EmStandardPhysicsWVI::G4EmStandardPhysicsWVI(), G4HadronElasticPhysics::G4HadronElasticPhysics(), G4HadronInelasticQBBC::G4HadronInelasticQBBC(), G4HadronPhysicsFTFP_BERT::G4HadronPhysicsFTFP_BERT(), G4HadronPhysicsQGSP_BERT::G4HadronPhysicsQGSP_BERT(), G4HadronPhysicsQGSP_BIC::G4HadronPhysicsQGSP_BIC(), G4IonINCLXXPhysics::G4IonINCLXXPhysics(), G4IonPhysics::G4IonPhysics(), G4IonPhysicsPHP::G4IonPhysicsPHP(), G4IonQMDPhysics::G4IonQMDPhysics(), G4NeutronTrackingCut::G4NeutronTrackingCut(), G4StepLimiterPhysics::G4StepLimiterPhysics(), G4StoppingPhysics::G4StoppingPhysics(), and G4StoppingPhysicsFritiofWithBinaryCascade::G4StoppingPhysicsFritiofWithBinaryCascade().

◆ SetVerboseLevel()

void G4VPhysicsConstructor::SetVerboseLevel ( G4int  value)
inline

◆ TerminateWorker()

void G4VPhysicsConstructor::TerminateWorker ( )
virtual

Definition at line 105 of file G4VPhysicsConstructor.cc.

106{
107 if(subInstanceManager.offset[g4vpcInstanceID]._builders != nullptr)
108 {
109 std::for_each(subInstanceManager.offset[g4vpcInstanceID]._builders->begin(),
110 subInstanceManager.offset[g4vpcInstanceID]._builders->end(),
111 [](PhysicsBuilder_V::value_type bld) { delete bld; });
112 subInstanceManager.offset[g4vpcInstanceID]._builders->clear();
113 }
114}

References g4vpcInstanceID, G4VUPLSplitter< T >::offset, and subInstanceManager.

Referenced by ~G4VPhysicsConstructor().

Field Documentation

◆ g4vpcInstanceID

G4int G4VPhysicsConstructor::g4vpcInstanceID = 0
protected

◆ namePhysics

G4String G4VPhysicsConstructor::namePhysics = ""
protected

◆ subInstanceManager

G4VPCManager G4VPhysicsConstructor::subInstanceManager
staticprotected

◆ theParticleTable

G4ParticleTable* G4VPhysicsConstructor::theParticleTable = nullptr
protected

◆ typePhysics

G4int G4VPhysicsConstructor::typePhysics = 0
protected

Definition at line 167 of file G4VPhysicsConstructor.hh.

Referenced by G4VPhysicsConstructor(), GetPhysicsType(), and SetPhysicsType().

◆ verboseLevel

G4int G4VPhysicsConstructor::verboseLevel = 0
protected

The documentation for this class was generated from the following files: