BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
|
Wrapper for Geant4's G4FieldManager to distinguish primaries. More...
#include <BDSFieldManager.hh>
Public Member Functions | |
BDSFieldManager (G4Field *field=nullptr, G4ChordFinder *chordFinder=nullptr, G4bool fieldChangesEnergy=true) | |
BDSFieldManager (G4MagneticField *field) | |
virtual void | ConfigureForTrack (const G4Track *track) |
Private Attributes | |
G4bool | currentTrackIsPrimary |
Whether current track is a primary. | |
Wrapper for Geant4's G4FieldManager to distinguish primaries.
This implements the ConfigureForTrack virtual method that by default does nothing and flags the track as primary or not in BDSIntegratorMag.
Definition at line 38 of file BDSFieldManager.hh.
BDSFieldManager::BDSFieldManager | ( | G4Field * | field = nullptr , |
G4ChordFinder * | chordFinder = nullptr , |
||
G4bool | fieldChangesEnergy = true |
||
) |
Definition at line 28 of file BDSFieldManager.cc.
BDSFieldManager::BDSFieldManager | ( | G4MagneticField * | field | ) |
Definition at line 35 of file BDSFieldManager.cc.
|
inlinevirtual |
Definition at line 47 of file BDSFieldManager.hh.
|
virtual |
Check whether the track has parent ID == 0 and then flag as a primary.
Definition at line 40 of file BDSFieldManager.cc.
References currentTrackIsPrimary, and BDSIntegratorMag::currentTrackIsPrimary.
|
private |
Whether current track is a primary.
Definition at line 54 of file BDSFieldManager.hh.
Referenced by ConfigureForTrack().