Geant4  10.02.p03
Collimator100BeamLineMessenger Class Reference

#include <Collimator100BeamLineMessenger.hh>

Inheritance diagram for Collimator100BeamLineMessenger:
Collaboration diagram for Collimator100BeamLineMessenger:

Public Member Functions

 Collimator100BeamLineMessenger (Collimator100BeamLine *)
 
 ~Collimator100BeamLineMessenger ()
 
void SetNewValue (G4UIcommand *, G4String)
 
- Public Member Functions inherited from G4UImessenger
 G4UImessenger ()
 
 G4UImessenger (const G4String &path, const G4String &dsc, G4bool commandsToBeBroadcasted=true)
 
virtual ~G4UImessenger ()
 
virtual G4String GetCurrentValue (G4UIcommand *command)
 
G4bool operator== (const G4UImessenger &messenger) const
 
G4bool CommandsShouldBeInMaster () const
 

Private Attributes

Collimator100BeamLinecollimator100
 
G4UIdirectorybeamLineDir
 
G4UIdirectoryFinalCollimatorIORTDir
 
G4UIcmdWithADoubleAndUnitinnerRadiusFinalCollimatorIORTCmd
 
G4UIcmdWithADoubleAndUnitOuterRadiusFinalCollimatorIORTCmd
 

Additional Inherited Members

- Protected Member Functions inherited from G4UImessenger
G4String ItoS (G4int i)
 
G4String DtoS (G4double a)
 
G4String BtoS (G4bool b)
 
G4int StoI (G4String s)
 
G4double StoD (G4String s)
 
G4bool StoB (G4String s)
 
void AddUIcommand (G4UIcommand *newCommand)
 
void CreateDirectory (const G4String &path, const G4String &dsc, G4bool commandsToBeBroadcasted=true)
 
template<typename T >
T * CreateCommand (const G4String &cname, const G4String &dsc)
 
- Protected Attributes inherited from G4UImessenger
G4UIdirectorybaseDir
 
G4String baseDirName
 
G4bool commandsShouldBeInMaster
 

Detailed Description

Definition at line 52 of file Collimator100BeamLineMessenger.hh.

Constructor & Destructor Documentation

◆ Collimator100BeamLineMessenger()

Collimator100BeamLineMessenger::Collimator100BeamLineMessenger ( Collimator100BeamLine beamLine)

Definition at line 48 of file Collimator100BeamLineMessenger.cc.

49 :collimator100(beamLine)
50 
51 {
52 
53  beamLineDir = new G4UIdirectory("/beamLine/");
54  beamLineDir -> SetGuidance("set specification of range shifter");
55 
56  FinalCollimatorIORTDir = new G4UIdirectory("/beamLine/FinalCollimatorIORT/");
57  FinalCollimatorIORTDir -> SetGuidance("set specification of final collimator");
58 
59  innerRadiusFinalCollimatorIORTCmd = new G4UIcmdWithADoubleAndUnit("/beamLine/FinalCollimatorIORT/halfInnerRad",this);
60  innerRadiusFinalCollimatorIORTCmd -> SetGuidance("Set size of inner radius ( max 21.5 mm)");
61  innerRadiusFinalCollimatorIORTCmd -> SetParameterName("Size",false);
62  innerRadiusFinalCollimatorIORTCmd -> SetDefaultUnit("mm");
63  innerRadiusFinalCollimatorIORTCmd -> SetUnitCandidates("mm cm m");
64  innerRadiusFinalCollimatorIORTCmd -> AvailableForStates(G4State_Idle);
65 
66  OuterRadiusFinalCollimatorIORTCmd = new G4UIcmdWithADoubleAndUnit("/beamLine/FinalCollimatorIORT/halfOuterRad",this);
67  OuterRadiusFinalCollimatorIORTCmd -> SetGuidance("Set size of outer radius ( max 21.5 mm)");
68  OuterRadiusFinalCollimatorIORTCmd -> SetParameterName("Size",false);
69  OuterRadiusFinalCollimatorIORTCmd -> SetDefaultUnit("mm");
70  OuterRadiusFinalCollimatorIORTCmd -> SetUnitCandidates("mm cm m");
71  OuterRadiusFinalCollimatorIORTCmd -> AvailableForStates(G4State_Idle);
72 
73 }
G4UIcmdWithADoubleAndUnit * innerRadiusFinalCollimatorIORTCmd
G4UIcmdWithADoubleAndUnit * OuterRadiusFinalCollimatorIORTCmd

◆ ~Collimator100BeamLineMessenger()

Collimator100BeamLineMessenger::~Collimator100BeamLineMessenger ( )

Definition at line 75 of file Collimator100BeamLineMessenger.cc.

76 {
77 
80  delete FinalCollimatorIORTDir;
81  delete beamLineDir;
82 
83 
84 }
G4UIcmdWithADoubleAndUnit * innerRadiusFinalCollimatorIORTCmd
G4UIcmdWithADoubleAndUnit * OuterRadiusFinalCollimatorIORTCmd

Member Function Documentation

◆ SetNewValue()

void Collimator100BeamLineMessenger::SetNewValue ( G4UIcommand command,
G4String  newValue 
)
virtual

Reimplemented from G4UImessenger.

Definition at line 89 of file Collimator100BeamLineMessenger.cc.

90 {
91 
92 
93  if( command == innerRadiusFinalCollimatorIORTCmd )
94  { collimator100 -> SetInnerRadiusFinalCollimatorIORT
95  (innerRadiusFinalCollimatorIORTCmd -> GetNewDoubleValue(newValue));}
96 
97  else if( command == OuterRadiusFinalCollimatorIORTCmd )
98  { collimator100 -> SetOuterRadiusFinalCollimatorIORT
99  (OuterRadiusFinalCollimatorIORTCmd -> GetNewDoubleValue(newValue));}
100 
101 }
G4UIcmdWithADoubleAndUnit * innerRadiusFinalCollimatorIORTCmd
G4UIcmdWithADoubleAndUnit * OuterRadiusFinalCollimatorIORTCmd

Member Data Documentation

◆ beamLineDir

G4UIdirectory* Collimator100BeamLineMessenger::beamLineDir
private

Definition at line 66 of file Collimator100BeamLineMessenger.hh.

◆ collimator100

Collimator100BeamLine* Collimator100BeamLineMessenger::collimator100
private

Definition at line 63 of file Collimator100BeamLineMessenger.hh.

◆ FinalCollimatorIORTDir

G4UIdirectory* Collimator100BeamLineMessenger::FinalCollimatorIORTDir
private

Definition at line 68 of file Collimator100BeamLineMessenger.hh.

◆ innerRadiusFinalCollimatorIORTCmd

G4UIcmdWithADoubleAndUnit* Collimator100BeamLineMessenger::innerRadiusFinalCollimatorIORTCmd
private

Definition at line 74 of file Collimator100BeamLineMessenger.hh.

◆ OuterRadiusFinalCollimatorIORTCmd

G4UIcmdWithADoubleAndUnit* Collimator100BeamLineMessenger::OuterRadiusFinalCollimatorIORTCmd
private

Definition at line 78 of file Collimator100BeamLineMessenger.hh.


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