#include <DsPhysConsGeneral.h>
Inheritance diagram for DsPhysConsGeneral:
Public Types | |
SUCCESS | |
NO_INTERFACE | |
VERSMISMATCH | |
LAST_ERROR | |
enum | Status |
enum | Status |
enum | Status |
Public Member Functions | |
DsPhysConsGeneral (const std::string &type, const std::string &name, const IInterface *parent) | |
virtual | ~DsPhysConsGeneral () |
void | ConstructParticle () |
void | ConstructProcess () |
virtual StatusCode | initialize () |
virtual StatusCode | finalize () |
virtual G4VPhysicsConstructor * | physicsConstructor () const |
virtual unsigned long | release () |
StatusCode | release (const IInterface *interface) const |
virtual StatusCode | queryInterface (const InterfaceID &riid, void **ppvInterface)=0 |
virtual StatusCode | queryInterface (const InterfaceID &riid, void **ppvInterface)=0 |
virtual StatusCode | queryInterface (const InterfaceID &riid, void **ppvInterface)=0 |
virtual StatusCode | queryInterface (const InterfaceID &riid, void **ppvUnknown) |
virtual unsigned long | addRef ()=0 |
virtual unsigned long | addRef ()=0 |
virtual unsigned long | addRef ()=0 |
virtual unsigned long | addRef () |
virtual const std::string & | type () const =0 |
virtual const std::string & | type () const |
virtual const IInterface * | parent () const =0 |
virtual const IInterface * | parent () const |
virtual StatusCode | configure ()=0 |
virtual StatusCode | configure () |
virtual StatusCode | start ()=0 |
virtual StatusCode | start () |
virtual StatusCode | stop ()=0 |
virtual StatusCode | stop () |
virtual StatusCode | terminate ()=0 |
virtual StatusCode | terminate () |
virtual StatusCode | reinitialize ()=0 |
virtual StatusCode | reinitialize () |
virtual StatusCode | restart ()=0 |
virtual StatusCode | restart () |
virtual Gaudi::StateMachine::State | FSMState () const =0 |
virtual Gaudi::StateMachine::State | FSMState () const |
virtual StatusCode | sysInitialize ()=0 |
virtual StatusCode | sysInitialize () |
virtual StatusCode | sysStart ()=0 |
virtual StatusCode | sysStart () |
virtual StatusCode | sysStop ()=0 |
virtual StatusCode | sysStop () |
virtual StatusCode | sysFinalize ()=0 |
virtual StatusCode | sysFinalize () |
virtual StatusCode | sysReinitialize ()=0 |
virtual StatusCode | sysReinitialize () |
virtual StatusCode | sysRestart ()=0 |
virtual StatusCode | sysRestart () |
virtual unsigned long | refCount () const =0 |
virtual const std::string & | name () const =0 |
virtual const std::string & | name () const |
virtual void | handle (const Incident &i) |
IGiGaSvc * | gigaSvc () const |
IGiGaSetUpSvc * | setupSvc () const |
INTupleSvc * | ntupleSvc () const |
INTupleSvc * | evtColSvc () const |
IDataProviderSvc * | detSvc () const |
IDataProviderSvc * | evtSvc () const |
IIncidentSvc * | incSvc () const |
IChronoStatSvc * | chronoSvc () const |
IHistogramSvc * | histoSvc () const |
IAlgContextSvc * | contextSvc () const |
DataObject * | put (IDataProviderSvc *svc, DataObject *object, const std::string &address, const bool useRootInTES=true) const |
DataObject * | put (DataObject *object, const std::string &address, const bool useRootInTES=true) const |
Gaudi::Utils::GetData< TYPE >::return_type | get (IDataProviderSvc *svc, const std::string &location, const bool useRootInTES=true) const |
Gaudi::Utils::GetData< TYPE >::return_type | get (const std::string &location, const bool useRootInTES=true) const |
TYPE * | getDet (IDataProviderSvc *svc, const std::string &location) const |
TYPE * | getDet (const std::string &location) const |
bool | exist (IDataProviderSvc *svc, const std::string &location, const bool useRootInTES=true) const |
bool | exist (const std::string &location, const bool useRootInTES=true) const |
bool | existDet (IDataProviderSvc *svc, const std::string &location) const |
bool | existDet (const std::string &location) const |
TYPE * | getOrCreate (IDataProviderSvc *svc, const std::string &location, const bool useRootInTES=true) const |
TYPE * | getOrCreate (const std::string &location, const bool useRootInTES=true) const |
TOOL * | tool (const std::string &type, const std::string &name, const IInterface *parent=0, bool create=true) const |
TOOL * | tool (const std::string &type, const IInterface *parent=0, bool create=true) const |
SERVICE * | svc (const std::string &name, const bool create=true) const |
IUpdateManagerSvc * | updMgrSvc () const |
IDataProviderSvc * | fastContainersSvc () const |
StatusCode | Error (const std::string &msg, const StatusCode st=StatusCode::FAILURE, const size_t mx=10) const |
StatusCode | Warning (const std::string &msg, const StatusCode st=StatusCode::FAILURE, const size_t mx=10) const |
StatusCode | Print (const std::string &msg, const StatusCode st=StatusCode::SUCCESS, const MSG::Level lev=MSG::INFO) const |
StatusCode | Assert (const bool ok, const std::string &message="", const StatusCode sc=StatusCode(StatusCode::FAILURE, true)) const |
StatusCode | Assert (const bool ok, const char *message, const StatusCode sc=StatusCode(StatusCode::FAILURE, true)) const |
StatusCode | Exception (const std::string &msg, const GaudiException &exc, const StatusCode sc=StatusCode(StatusCode::FAILURE, true)) const |
StatusCode | Exception (const std::string &msg, const std::exception &exc, const StatusCode sc=StatusCode(StatusCode::FAILURE, true)) const |
StatusCode | Exception (const std::string &msg="no message", const StatusCode sc=StatusCode(StatusCode::FAILURE, true)) const |
MsgStream & | msgStream (const MSG::Level level) const |
MsgStream & | always () const |
MsgStream & | fatal () const |
MsgStream & | err () const |
MsgStream & | error () const |
MsgStream & | warning () const |
MsgStream & | info () const |
MsgStream & | debug () const |
MsgStream & | verbose () const |
MsgStream & | msg () const |
const Statistics & | counters () const |
StatEntity & | counter (const std::string &tag) const |
MSG::Level | msgLevel () const |
bool | msgLevel (const MSG::Level level) const |
void | resetMsgStream () const |
bool | typePrint () const |
bool | propsPrint () const |
bool | statPrint () const |
bool | errorsPrint () const |
long | printStat (const MSG::Level level=MSG::ALWAYS) const |
long | printErrors (const MSG::Level level=MSG::ALWAYS) const |
long | printProps (const MSG::Level level=MSG::ALWAYS) const |
void | registerCondition (const std::string &condition, StatusCode(CallerClass::*mf)()=NULL) |
void | registerCondition (const std::string &condition, CondType *&condPtrDest, StatusCode(CallerClass::*mf)()=NULL) |
void | registerCondition (char *condition, StatusCode(CallerClass::*mf)()=NULL) |
void | registerCondition (TargetClass *condition, StatusCode(CallerClass::*mf)()=NULL) |
StatusCode | runUpdate () |
TransientFastContainer< T > * | getFastContainer (const std::string &location, typename TransientFastContainer< T >::size_type initial=0) |
const std::string & | context () const |
const std::string & | rootInTES () const |
double | globalTimeOffset () const |
virtual Gaudi::StateMachine::State | targetFSMState () const |
virtual StatusCode | setProperty (const Property &p) |
virtual StatusCode | setProperty (const std::string &s) |
virtual StatusCode | setProperty (const std::string &n, const std::string &v) |
StatusCode | setProperty (const std::string &name, const TYPE &value) |
virtual StatusCode | getProperty (Property *p) const |
virtual const Property & | getProperty (const std::string &name) const |
virtual StatusCode | getProperty (const std::string &n, std::string &v) const |
virtual const std::vector< Property * > & | getProperties () const |
PropertyMgr * | getPropertyMgr () |
ISvcLocator * | serviceLocator () const |
ISvcLocator * | svcLoc () const |
IMessageSvc * | msgSvc () const |
IToolSvc * | toolSvc () const |
StatusCode | setProperties () |
StatusCode | service (const std::string &name, T *&svc, bool createIf=true) const |
StatusCode | service (const std::string &type, const std::string &name, T *&svc) const |
void | declInterface (const InterfaceID &, void *) |
Property * | declareProperty (const std::string &name, T &property, const std::string &doc="none") const |
Property * | declareRemoteProperty (const std::string &name, IProperty *rsvc, const std::string &rname="") const |
IAuditorSvc * | auditorSvc () const |
IMonitorSvc * | monitorSvc () const |
void | declareInfo (const std::string &name, const T &var, const std::string &desc) const |
void | declareInfo (const std::string &name, const std::string &format, const void *var, int size, const std::string &desc) const |
Static Public Member Functions | |
static const InterfaceID & | interfaceID () |
static const InterfaceID & | interfaceID () |
static const InterfaceID & | interfaceID () |
Public Attributes | |
SUCCESS | |
NO_INTERFACE | |
VERSMISMATCH | |
LAST_ERROR | |
Protected Types | |
typedef std::map< std::string, StatEntity > | Statistics |
typedef std::map< std::string, unsigned int > | Counter |
typedef std::vector< IAlgTool * > | AlgTools |
typedef std::pair< IInterface *, std::string > | ServiceEntry |
typedef std::vector< ServiceEntry > | Services |
Protected Member Functions | |
virtual unsigned long | refCount () const |
StatusCode | releaseTool (const IAlgTool *tool) const |
StatusCode | releaseSvc (const IInterface *svc) const |
int | outputLevel () const |
IntegerProperty & | outputLevelProperty () |
void | initOutputLevel (Property &prop) |
Static Protected Attributes | |
static const bool | IgnoreRootInTES |
static const bool | UseRootInTES |
Private Attributes | |
float | m_lowProdCut |
Set production range. | |
float | m_highProdCut |
float | m_gammaCut |
Per particle cuts. | |
float | m_electronCut |
float | m_positronCut |
Construct general physics particles and processes.
Definition at line 12 of file DsPhysConsGeneral.h.
DsPhysConsGeneral::DsPhysConsGeneral | ( | const std::string & | type, | |
const std::string & | name, | |||
const IInterface * | parent | |||
) |
Definition at line 7 of file DsPhysConsGeneral.cc.
00010 : GiGaPhysConstructorBase(type,name,parent) 00011 { 00012 declareProperty("LowProdCut", m_lowProdCut=250*eV, 00013 "Lower bound on production energy"); 00014 declareProperty("HighProdCut", m_highProdCut=100*GeV, 00015 "Upper bound on production energy"); 00016 00017 declareProperty("GammaCut",m_gammaCut=1.0*mm, 00018 "Cut for gammas"); 00019 declareProperty("ElectronCut",m_electronCut=100.0*micrometer, 00020 "Cut for electrons"); 00021 declareProperty("PositronCut", m_positronCut=100.0*micrometer, 00022 "Cut for positrons"); 00023 }
DsPhysConsGeneral::~DsPhysConsGeneral | ( | ) | [virtual] |
void DsPhysConsGeneral::ConstructParticle | ( | ) |
Definition at line 43 of file DsPhysConsGeneral.cc.
00044 { 00045 { // All bosons 00046 G4BosonConstructor con; 00047 con.ConstructParticle(); 00048 } 00049 { // All leptons 00050 G4LeptonConstructor con; 00051 con.ConstructParticle(); 00052 } 00053 { /* Adopted a subset of mesons to avoid segv at the very end of 00054 * the run (seems to be related with B mesons and hLowEIoni???). 00055 * Carbon-copied the meson list from the example in 00056 * advanced/underground/physics. Jianglai 05/08/2006 00057 */ 00058 G4PionPlus::PionPlusDefinition(); 00059 G4PionMinus::PionMinusDefinition(); 00060 G4PionZero::PionZeroDefinition(); 00061 G4KaonPlus::KaonPlusDefinition(); 00062 G4KaonMinus::KaonMinusDefinition(); 00063 G4Eta::EtaDefinition(); 00064 G4EtaPrime::EtaPrimeDefinition(); 00065 G4KaonZero::KaonZeroDefinition(); 00066 G4AntiKaonZero::AntiKaonZeroDefinition(); 00067 G4KaonZeroLong::KaonZeroLongDefinition(); 00068 G4KaonZeroShort::KaonZeroShortDefinition(); 00069 } 00070 { // All baryons 00071 G4BaryonConstructor con; 00072 con.ConstructParticle(); 00073 } 00074 { // All ions 00075 G4IonConstructor con; 00076 con.ConstructParticle(); 00077 } 00078 00079 { // all short lived (resonaces and quarks) 00080 G4ShortLivedConstructor con; 00081 con.ConstructParticle(); 00082 } 00083 00085 G4ParticlePropertyTable* propTable = G4ParticlePropertyTable::GetParticlePropertyTable(); 00086 assert(propTable); 00087 G4ParticlePropertyData* photonData = propTable->GetParticleProperty(G4OpticalPhoton::Definition()); 00088 assert(photonData); 00089 photonData->SetPDGEncoding(20022); 00090 photonData->SetAntiPDGEncoding(20022); 00091 if(propTable->SetParticleProperty(*photonData)) 00092 info() << "Set PDG code for opticalphoton to " << G4OpticalPhoton::Definition()->GetPDGEncoding() << endreq; 00093 else 00094 warning() << "Failed to reset PDG code on opticalphoton.. it's still set to " 00095 << G4OpticalPhoton::Definition()->GetPDGEncoding() << endreq; 00096 }
void DsPhysConsGeneral::ConstructProcess | ( | ) |
Definition at line 98 of file DsPhysConsGeneral.cc.
00099 { 00100 // can't call this from a GiGaPhysConstructorBase, but 00101 // G4VModularPhysicsList will do it for us. 00102 // AddTransportation(); 00103 00104 G4Decay* theDecayProcess = new G4Decay(); 00105 theParticleIterator->reset(); 00106 while( (*theParticleIterator)() ) { 00107 G4ParticleDefinition* particle = theParticleIterator->value(); 00108 G4ProcessManager* pmanager = particle->GetProcessManager(); 00109 if (theDecayProcess->IsApplicable(*particle)) { 00110 pmanager->AddDiscreteProcess(theDecayProcess); 00111 pmanager ->SetProcessOrdering(theDecayProcess, idxPostStep); 00112 pmanager ->SetProcessOrdering(theDecayProcess, idxAtRest); 00113 } 00114 } 00115 00116 const G4IonTable* theIonTable 00117 = G4ParticleTable::GetParticleTable()->GetIonTable(); 00118 //G4RadioactiveDecay* theRadioactiveDecay = new G4RadioactiveDecay(); 00119 DsG4RadioactiveDecay* theRadioactiveDecay = new DsG4RadioactiveDecay(); 00120 for (G4int i=0; i<theIonTable->Entries(); i++) { 00121 G4String particleName = theIonTable->GetParticle(i)->GetParticleName(); 00122 if (particleName == "GenericIon") { 00123 G4ProcessManager* pmanager 00124 = theIonTable->GetParticle(i)->GetProcessManager(); 00125 pmanager ->AddProcess(theRadioactiveDecay); 00126 pmanager ->SetProcessOrdering(theRadioactiveDecay, idxPostStep); 00127 pmanager ->SetProcessOrdering(theRadioactiveDecay, idxAtRest); 00128 } 00129 } 00130 00131 }
float DsPhysConsGeneral::m_lowProdCut [private] |
float DsPhysConsGeneral::m_highProdCut [private] |
Definition at line 26 of file DsPhysConsGeneral.h.
float DsPhysConsGeneral::m_gammaCut [private] |
float DsPhysConsGeneral::m_electronCut [private] |
Definition at line 29 of file DsPhysConsGeneral.h.
float DsPhysConsGeneral::m_positronCut [private] |
Definition at line 29 of file DsPhysConsGeneral.h.