Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4WeightWindowConfigurator Class Reference

#include <G4WeightWindowConfigurator.hh>

+ Inheritance diagram for G4WeightWindowConfigurator:

Public Member Functions

 G4WeightWindowConfigurator (G4VPhysicalVolume *worldvolume, const G4String &particlename, G4VWeightWindowStore &wwstore, const G4VWeightWindowAlgorithm *wwAlg, G4PlaceOfAction placeOfAction, G4bool paraflag)
 
virtual ~G4WeightWindowConfigurator ()
 
virtual void Configure (G4VSamplerConfigurator *preConf)
 
virtual const G4VTrackTerminatorGetTrackTerminator () const
 
- Public Member Functions inherited from G4VSamplerConfigurator
 G4VSamplerConfigurator ()
 
virtual ~G4VSamplerConfigurator ()
 
virtual void Configure (G4VSamplerConfigurator *preConf)=0
 
virtual const G4VTrackTerminatorGetTrackTerminator () const =0
 

Detailed Description

Definition at line 51 of file G4WeightWindowConfigurator.hh.

Constructor & Destructor Documentation

◆ G4WeightWindowConfigurator()

G4WeightWindowConfigurator::G4WeightWindowConfigurator ( G4VPhysicalVolume worldvolume,
const G4String particlename,
G4VWeightWindowStore wwstore,
const G4VWeightWindowAlgorithm wwAlg,
G4PlaceOfAction  placeOfAction,
G4bool  paraflag 
)

Definition at line 39 of file G4WeightWindowConfigurator.cc.

45 : fWorld(worldvolume),
46 fPlacer(particlename),
47 fWeightWindowStore(wwstore),
48 fDeleteWWalg( ( ! wwAlg) ),
49 fWWalgorithm(( (fDeleteWWalg) ?
50 new G4WeightWindowAlgorithm(5,3,5) : wwAlg)),
51 fWeightWindowProcess(0),
52 fPlaceOfAction(placeOfAction)
53{
54 paraflag = para;
55}

◆ ~G4WeightWindowConfigurator()

G4WeightWindowConfigurator::~G4WeightWindowConfigurator ( )
virtual

Definition at line 57 of file G4WeightWindowConfigurator.cc.

58{
59 if (fWeightWindowProcess)
60 {
61 fPlacer.RemoveProcess(fWeightWindowProcess);
62 delete fWeightWindowProcess;
63 }
64 if (fDeleteWWalg)
65 {
66 delete fWWalgorithm;
67 }
68}
virtual void RemoveProcess(G4VProcess *process)

Member Function Documentation

◆ Configure()

void G4WeightWindowConfigurator::Configure ( G4VSamplerConfigurator preConf)
virtual

Implements G4VSamplerConfigurator.

Definition at line 71 of file G4WeightWindowConfigurator.cc.

72{
73 G4cout << " entering weight window configure " << G4endl;
74 const G4VTrackTerminator *terminator = 0;
75 if (preConf)
76 {
77 terminator = preConf->GetTrackTerminator();
78 };
79
80 fWeightWindowProcess =
81 new G4WeightWindowProcess(*fWWalgorithm,
82 fWeightWindowStore,
83 terminator,
84 fPlaceOfAction,"WeightWindowProcess",paraflag);
85
86 if(paraflag) fWeightWindowProcess->SetParallelWorld(fWorld);
87
88 fPlacer.AddProcessAsSecondDoIt(fWeightWindowProcess);
89}
#define G4endl
Definition: G4ios.hh:52
G4DLLIMPORT std::ostream G4cout
virtual void AddProcessAsSecondDoIt(G4VProcess *process)
virtual const G4VTrackTerminator * GetTrackTerminator() const =0
void SetParallelWorld(G4String parallelWorldName)

◆ GetTrackTerminator()

const G4VTrackTerminator * G4WeightWindowConfigurator::GetTrackTerminator ( ) const
virtual

Implements G4VSamplerConfigurator.

Definition at line 92 of file G4WeightWindowConfigurator.cc.

93{
94 return fWeightWindowProcess;
95}

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