QwGeant4
QweakSimBeamLineMessenger Class Reference

Placeholder for a long explaination. More...

#include <QweakSimBeamLineMessenger.hh>

Inherits G4UImessenger.

+ Collaboration diagram for QweakSimBeamLineMessenger:

Public Member Functions

 QweakSimBeamLineMessenger (QweakSimBeamLine *)
 
 ~QweakSimBeamLineMessenger ()
 
void SetNewValue (G4UIcommand *, G4String)
 

Private Attributes

QweakSimBeamLinemyBeamLine
 
G4UIdirectory * BeamLineDir
 
G4UIcmdWithAString * BeamLineMatCmd
 
G4UIcmdWithADoubleAndUnit * BeamLineZPosCmd
 

Detailed Description

Placeholder for a long explaination.

Definition at line 43 of file QweakSimBeamLineMessenger.hh.

Constructor & Destructor Documentation

QweakSimBeamLineMessenger::QweakSimBeamLineMessenger ( QweakSimBeamLine myTar)

Definition at line 28 of file QweakSimBeamLineMessenger.cc.

References BeamLineDir, BeamLineMatCmd, and BeamLineZPosCmd.

Referenced by QweakSimBeamLine::QweakSimBeamLine().

29 :myBeamLine(myTar)
30 {
31  // BeamLine related
32  BeamLineDir = new G4UIdirectory("/BeamLine/");
33  BeamLineDir -> SetGuidance("beamline control.");
34 
35  BeamLineZPosCmd = new G4UIcmdWithADoubleAndUnit("/BeamLine/SetCenterPositionInZ",this);
36  BeamLineZPosCmd->SetGuidance("Set the Z position of the target center");
37  BeamLineZPosCmd->SetParameterName("Size",true);
38  //TargZPosCmd->SetRange("Size>=0.");
39  BeamLineZPosCmd->SetUnitCategory("Length");
40  BeamLineZPosCmd->AvailableForStates(G4State_PreInit,G4State_Idle);
41 
42  BeamLineMatCmd = new G4UIcmdWithAString("/BeamLine/SetBeamLineMaterial",this);
43  BeamLineMatCmd->SetGuidance("Select Material of the BeamLine.");
44  BeamLineMatCmd->SetParameterName("choice",false);
45  BeamLineMatCmd->AvailableForStates(G4State_PreInit,G4State_Idle);
46 
47 }
G4UIcmdWithADoubleAndUnit * BeamLineZPosCmd

+ Here is the caller graph for this function:

QweakSimBeamLineMessenger::~QweakSimBeamLineMessenger ( )

Definition at line 51 of file QweakSimBeamLineMessenger.cc.

References BeamLineDir, BeamLineMatCmd, and BeamLineZPosCmd.

52 {
53  delete BeamLineZPosCmd;
54  delete BeamLineMatCmd;
55  delete BeamLineDir;
56 }
G4UIcmdWithADoubleAndUnit * BeamLineZPosCmd

Member Function Documentation

void QweakSimBeamLineMessenger::SetNewValue ( G4UIcommand *  command,
G4String  newValue 
)

Definition at line 60 of file QweakSimBeamLineMessenger.cc.

References BeamLineMatCmd, BeamLineZPosCmd, myBeamLine, QweakSimBeamLine::SetBeamLineCenterPositionInZ(), and QweakSimBeamLine::SetBeamLineMaterial().

61 {
62  G4cout << "#### Calling QweakSimBeamLineMessenger::SetNewValue() " << newValue << G4endl;
63 
64  if( command == BeamLineZPosCmd )
65  {
66  G4cout << "#### Messenger: Setting BeamLine Z position to " << newValue << G4endl;
67 
68  myBeamLine->SetBeamLineCenterPositionInZ(BeamLineZPosCmd->GetNewDoubleValue(newValue));
69  }
70 
71  if( command == BeamLineMatCmd )
72  {
73  G4cout << "#### Messenger: Setting BeamLine Material to " << newValue << G4endl;
74 
76  }
77 
78 
79  G4cout << "#### Leaving QweakSimBeamLineMessenger::SetNewValue() " << newValue << G4endl;
80 }
void SetBeamLineCenterPositionInZ(G4double)
G4UIcmdWithADoubleAndUnit * BeamLineZPosCmd
void SetBeamLineMaterial(G4String)

+ Here is the call graph for this function:

Field Documentation

G4UIdirectory* QweakSimBeamLineMessenger::BeamLineDir
private
G4UIcmdWithAString* QweakSimBeamLineMessenger::BeamLineMatCmd
private
G4UIcmdWithADoubleAndUnit* QweakSimBeamLineMessenger::BeamLineZPosCmd
private
QweakSimBeamLine* QweakSimBeamLineMessenger::myBeamLine
private

Definition at line 52 of file QweakSimBeamLineMessenger.hh.

Referenced by SetNewValue().


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