19#include "BDSPhysicsSynchRad.hh"
22#include "G4AutoDelete.hh"
24#include "G4LeptonConstructor.hh"
25#include "G4OpticalPhoton.hh"
26#include "G4ParticleDefinition.hh"
27#include "G4SynchrotronRadiation.hh"
28#include "G4Version.hh"
30BDSPhysicsSynchRad::BDSPhysicsSynchRad():
31 G4VPhysicsConstructor(
"BDSPhysicsSynchRad")
34BDSPhysicsSynchRad::~BDSPhysicsSynchRad()
39 G4LeptonConstructor leptons;
40 leptons.ConstructParticle();
43 G4OpticalPhoton::OpticalPhotonDefinition();
51 G4SynchrotronRadiation* synchrotron =
new G4SynchrotronRadiation();
52 G4AutoDelete::Register(synchrotron);
54 G4PhysicsListHelper* ph = G4PhysicsListHelper::GetPhysicsListHelper();
56#if G4VERSION_NUMBER > 1029
57 auto aParticleIterator = GetParticleIterator();
59 aParticleIterator->reset();
60 while( (*aParticleIterator)() )
62 G4ParticleDefinition* particle = aParticleIterator->value();
64 if (particle->GetPDGCharge() != 0)
65 {ph->RegisterProcess(synchrotron, particle);}
virtual void ConstructProcess()
Construct and attach G4SynchrotronRadiation to all charged particles.
virtual void ConstructParticle()
Construct all leptons and the photon.
G4bool Activated() const
Get whether this instance has been activated.
void SetActivated()
Flag this instance as activated for later querying.