Geant4  10.02.p03
HadrontherapyGeometryController Class Reference

#include <HadrontherapyGeometryController.hh>

Collaboration diagram for HadrontherapyGeometryController:

Public Member Functions

 HadrontherapyGeometryController ()
 
 ~HadrontherapyGeometryController ()
 
void SetGeometry (G4String)
 

Private Member Functions

void registerGeometry (G4VUserDetectorConstruction *detector)
 

Detailed Description

Controller for geometry selection

This controller is called by the geometry messenger and used to select the geometry. Each available geometry must have unique name and it must be known by the geometry controller.

Definition at line 42 of file HadrontherapyGeometryController.hh.

Constructor & Destructor Documentation

◆ HadrontherapyGeometryController()

HadrontherapyGeometryController::HadrontherapyGeometryController ( )

Definition at line 42 of file HadrontherapyGeometryController.cc.

43 {}

◆ ~HadrontherapyGeometryController()

HadrontherapyGeometryController::~HadrontherapyGeometryController ( )

Definition at line 46 of file HadrontherapyGeometryController.cc.

47 {}

Member Function Documentation

◆ registerGeometry()

void HadrontherapyGeometryController::registerGeometry ( G4VUserDetectorConstruction detector)
private

Definition at line 72 of file HadrontherapyGeometryController.cc.

73 {
75  runManager -> SetUserInitialization(detector);
76  runManager -> GeometryHasBeenModified();
77 }
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:79
Here is the call graph for this function:
Here is the caller graph for this function:

◆ SetGeometry()

void HadrontherapyGeometryController::SetGeometry ( G4String  name)

Select a geometry by name.

Definition at line 50 of file HadrontherapyGeometryController.cc.

51 {
52  G4cout <<"Activating geometry " << name << G4endl;
53  if(name == "default")
54  {
56  }
57  else if(name == "Carbon")
58  {
60  }
61  else if(name == "LaserDriven")
62  {
64  }
65  else
66  {
67  G4cout <<"Unknown geometry: " << name << ". Geometry not changed." << G4endl;
68  }
69 }
void registerGeometry(G4VUserDetectorConstruction *detector)
G4GLOB_DLL std::ostream G4cout
#define G4endl
Definition: G4ios.hh:61
Here is the call graph for this function:
Here is the caller graph for this function:

The documentation for this class was generated from the following files: