Geant4  10.02.p03
GammaRayTelPrimaryGeneratorMessenger Class Reference

#include <GammaRayTelPrimaryGeneratorMessenger.hh>

Inheritance diagram for GammaRayTelPrimaryGeneratorMessenger:
Collaboration diagram for GammaRayTelPrimaryGeneratorMessenger:

Public Member Functions

 GammaRayTelPrimaryGeneratorMessenger (GammaRayTelPrimaryGeneratorAction *)
 
 ~GammaRayTelPrimaryGeneratorMessenger ()
 
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

GammaRayTelPrimaryGeneratorActionGammaRayTelAction
 
G4UIcmdWithAStringRndmCmd
 
G4UIcmdWithAnIntegerSourceTypeCmd
 
G4UIcmdWithADoubleAndUnitVertexRadiusCmd
 
G4UIcmdWithAnIntegerSpectrumTypeCmd
 
G4UIcmdWithABoolSourceGenCmd
 

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 57 of file GammaRayTelPrimaryGeneratorMessenger.hh.

Constructor & Destructor Documentation

◆ GammaRayTelPrimaryGeneratorMessenger()

GammaRayTelPrimaryGeneratorMessenger::GammaRayTelPrimaryGeneratorMessenger ( GammaRayTelPrimaryGeneratorAction GammaRayTelGun)

Definition at line 53 of file GammaRayTelPrimaryGeneratorMessenger.cc.

54  :GammaRayTelAction(GammaRayTelGun)
55 {
56  RndmCmd = new G4UIcmdWithAString("/gun/random",this);
57  RndmCmd->SetGuidance("Shoot randomly the incident particle.");
58  RndmCmd->SetGuidance(" Choice : on(default), off");
59  RndmCmd->SetParameterName("choice",true);
60  RndmCmd->SetDefaultValue("on");
61  RndmCmd->SetCandidates("on off");
63 
64  SourceTypeCmd = new G4UIcmdWithAnInteger("/gun/sourceType",this);
65  SourceTypeCmd->SetGuidance("Select the type of incident flux.");
66  SourceTypeCmd->SetGuidance(" Choice : 0(default), 1(isotropic), 2(wide parallel beam)");
67  SourceTypeCmd->SetParameterName("choice",true);
70 
71  VertexRadiusCmd = new G4UIcmdWithADoubleAndUnit("/gun/vertexRadius",this);
72  VertexRadiusCmd->SetGuidance("Radius (and unit) of sphere for vertices of incident flux.");
73  VertexRadiusCmd->SetParameterName("choice",true);
76 
77  SpectrumTypeCmd = new G4UIcmdWithAnInteger("/gun/spectrumType",this);
78  SpectrumTypeCmd->SetGuidance("Select the type of incident spectrum.");
79  SpectrumTypeCmd->SetGuidance(" Choice : 0(default), 1(), 2(E^{-gamma}), 3()");
80  SpectrumTypeCmd->SetParameterName("choice",true);
83 
84 
85  SourceGenCmd = new G4UIcmdWithABool("/gun/sourceGen",this);
86  SourceGenCmd->SetGuidance("Select the native Generation");
87  SourceGenCmd->SetGuidance(" Choice : true(native), false(GPS)");
88  SourceGenCmd->SetParameterName("choice",true);
91 
92 }
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
static const double cm
Definition: G4SIunits.hh:118
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
int G4int
Definition: G4Types.hh:78
void SetDefaultValue(G4bool defVal)
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
bool G4bool
Definition: G4Types.hh:79
void SetGuidance(const char *aGuidance)
Definition: G4UIcommand.hh:161
void AvailableForStates(G4ApplicationState s1)
Definition: G4UIcommand.cc:239
void SetDefaultValue(const char *defVal)
GammaRayTelPrimaryGeneratorAction * GammaRayTelAction
void SetCandidates(const char *candidateList)
void SetDefaultValue(G4int defVal)
double G4double
Definition: G4Types.hh:76
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)

◆ ~GammaRayTelPrimaryGeneratorMessenger()

GammaRayTelPrimaryGeneratorMessenger::~GammaRayTelPrimaryGeneratorMessenger ( )

Member Function Documentation

◆ SetNewValue()

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

Reimplemented from G4UImessenger.

Definition at line 107 of file GammaRayTelPrimaryGeneratorMessenger.cc.

108 {
109  if( command == RndmCmd )
110  { GammaRayTelAction->SetRndmFlag(newValue);}
111 
112  if( command == SourceTypeCmd )
114 
115  if( command == VertexRadiusCmd )
117 
118  if( command == SpectrumTypeCmd )
120 
121  if( command == SourceGenCmd )
123 }
static G4int GetNewIntValue(const char *paramString)
static G4double GetNewDoubleValue(const char *paramString)
static G4bool GetNewBoolValue(const char *paramString)
GammaRayTelPrimaryGeneratorAction * GammaRayTelAction
Here is the call graph for this function:

Member Data Documentation

◆ GammaRayTelAction

GammaRayTelPrimaryGeneratorAction* GammaRayTelPrimaryGeneratorMessenger::GammaRayTelAction
private

Definition at line 66 of file GammaRayTelPrimaryGeneratorMessenger.hh.

◆ RndmCmd

G4UIcmdWithAString* GammaRayTelPrimaryGeneratorMessenger::RndmCmd
private

Definition at line 67 of file GammaRayTelPrimaryGeneratorMessenger.hh.

◆ SourceGenCmd

G4UIcmdWithABool* GammaRayTelPrimaryGeneratorMessenger::SourceGenCmd
private

Definition at line 71 of file GammaRayTelPrimaryGeneratorMessenger.hh.

◆ SourceTypeCmd

G4UIcmdWithAnInteger* GammaRayTelPrimaryGeneratorMessenger::SourceTypeCmd
private

Definition at line 68 of file GammaRayTelPrimaryGeneratorMessenger.hh.

◆ SpectrumTypeCmd

G4UIcmdWithAnInteger* GammaRayTelPrimaryGeneratorMessenger::SpectrumTypeCmd
private

Definition at line 70 of file GammaRayTelPrimaryGeneratorMessenger.hh.

◆ VertexRadiusCmd

G4UIcmdWithADoubleAndUnit* GammaRayTelPrimaryGeneratorMessenger::VertexRadiusCmd
private

Definition at line 69 of file GammaRayTelPrimaryGeneratorMessenger.hh.


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