Geant4  10.03.p03
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
pyMedicalBeam Namespace Reference

Functions

MedicalBeamConstruct ()
 
void SetParticleByName (MedicalBeam *beam, const std::string &pname)
 
std::string GetParticleByName (MedicalBeam *beam)
 
void f_SetFieldXY (MedicalBeam *beam, const list &listXY)
 
list f_GetFieldXY (MedicalBeam *beam)
 

Function Documentation

MedicalBeam* pyMedicalBeam::Construct ( )

Definition at line 49 of file pyMedicalBeam.cc.

50 {
52 
53  MedicalBeam* medicalbeam= new MedicalBeam();
54  runMgr-> SetUserAction(medicalbeam);
55 
56  return medicalbeam;
57 }
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:79

Here is the call graph for this function:

list pyMedicalBeam::f_GetFieldXY ( MedicalBeam beam)

Definition at line 95 of file pyMedicalBeam.cc.

97 {
98  list listFieldXY;
99 
100  listFieldXY.append(beam-> GetFieldX());
101  listFieldXY.append(beam-> GetFieldY());
102 
103  return listFieldXY;
104 }

Here is the caller graph for this function:

void pyMedicalBeam::f_SetFieldXY ( MedicalBeam beam,
const list &  listXY 
)

Definition at line 85 of file pyMedicalBeam.cc.

87 {
88  G4double fx= extract<double>(listXY[0]);
89  G4double fy= extract<double>(listXY[1]);
90  beam-> SetFieldXY(fx, fy);
91 }
double G4double
Definition: G4Types.hh:76

Here is the caller graph for this function:

std::string pyMedicalBeam::GetParticleByName ( MedicalBeam beam)

Definition at line 75 of file pyMedicalBeam.cc.

77 {
78  const G4ParticleDefinition* pd= beam-> GetParticleDefinition();
79 
80  if(pd==0) return std::string("None");
81  else return (pd-> GetParticleName()).c_str();
82 }

Here is the caller graph for this function:

void pyMedicalBeam::SetParticleByName ( MedicalBeam beam,
const std::string &  pname 
)

Definition at line 61 of file pyMedicalBeam.cc.

63 {
65  G4ParticleDefinition* pd= particleTable-> FindParticle(pname);
66  if (pd != 0) {
67  beam-> SetParticleDefinition(pd);
68  } else {
69  G4cout << "*** \"" << pname << "\" is not registered "
70  << "in available particle list" << G4endl;
71  }
72 }
G4GLOB_DLL std::ostream G4cout
string pname
Definition: eplot.py:33
static G4ParticleTable * GetParticleTable()
#define G4endl
Definition: G4ios.hh:61

Here is the call graph for this function:

Here is the caller graph for this function: