CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
G4RPGProtonBuilder.cc
Go to the documentation of this file.
1 #include "SimG4Core/PhysicsLists/interface/G4RPGProtonBuilder.hh"
2 #include "G4ParticleDefinition.hh"
3 #include "G4ParticleTable.hh"
4 #include "G4ProcessManager.hh"
5 
6 G4RPGProtonBuilder::G4RPGProtonBuilder(): theRPGProtonModel(0) {
7  theMin = 0;
8  theMax = 55*GeV;
9 }
10 
11 G4RPGProtonBuilder::~G4RPGProtonBuilder() {
12  if (theRPGProtonModel) delete theRPGProtonModel;
13 }
14 
15 void G4RPGProtonBuilder::Build(G4HadronElasticProcess *) {
16  G4cout << "Info - G4RPGProtonBuilder::Build() not adding elastic" << G4endl;
17 }
18 
19 void G4RPGProtonBuilder::Build(G4ProtonInelasticProcess * aP) {
20  theRPGProtonModel = new G4RPGProtonInelastic();
21  theRPGProtonModel->SetMinEnergy(theMin);
22  theRPGProtonModel->SetMaxEnergy(theMax);
23  aP->RegisterMe(theRPGProtonModel);
24 }