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

#include <DMXRunActionMessenger.hh>

Inheritance diagram for DMXRunActionMessenger:
Collaboration diagram for DMXRunActionMessenger:

Public Member Functions

 DMXRunActionMessenger (DMXRunAction *)
 
 ~DMXRunActionMessenger ()
 
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
 

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 54 of file DMXRunActionMessenger.hh.

Constructor & Destructor Documentation

DMXRunActionMessenger::DMXRunActionMessenger ( DMXRunAction run)

Definition at line 55 of file DMXRunActionMessenger.cc.

56 :DMXRun(run)
57 {
58  SaveHitsCmd = new G4UIcmdWithAString("/dmx/hitsfile",this);
59  SaveHitsCmd->SetGuidance("output file for hits collection (txt)");
60  SaveHitsCmd->SetGuidance("Default = hits.out");
61  SaveHitsCmd->SetParameterName("savehitsFile", false);
62  SaveHitsCmd->SetDefaultValue("hits.out");
63 
64  SavePmtCmd = new G4UIcmdWithAString("/dmx/pmtfile",this);
65  SavePmtCmd->SetGuidance("output file for pmt hits (txt)");
66  SavePmtCmd->SetGuidance("Default = pmt.out");
67  SavePmtCmd->SetParameterName("savepmtFile", false);
68  SavePmtCmd->SetDefaultValue("pmt.out");
69 
70  SaveHistFileCmd = new G4UIcmdWithAString("/dmx/histogramfile",this);
71  SaveHistFileCmd->SetGuidance("output file for histograms");
72  SaveHistFileCmd->SetGuidance("Default = dmx.his");
73  // SaveHistFileCmd->SetParameterName("savehistFile", false);
74  SaveHistFileCmd->SetParameterName("histFile", false);
75  SaveHistFileCmd->SetDefaultValue("dmx.his");
76 
77 
78  // FileCmd->AvailableForStates(G4State_Idle);
79 }
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
void SetGuidance(const char *aGuidance)
Definition: G4UIcommand.hh:161
void SetDefaultValue(const char *defVal)

Here is the call graph for this function:

DMXRunActionMessenger::~DMXRunActionMessenger ( )

Definition at line 83 of file DMXRunActionMessenger.cc.

84 {
85  delete SaveHitsCmd;
86  delete SavePmtCmd;
87  delete SaveHistFileCmd;
88 }

Member Function Documentation

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

Reimplemented from G4UImessenger.

Definition at line 92 of file DMXRunActionMessenger.cc.

93 {
94  if(command == SaveHitsCmd)
95  DMXRun->SetsavehitsFile(newValue);
96 
97  if(command == SavePmtCmd)
98  DMXRun->SetsavepmtFile(newValue);
99 
100  if(command == SaveHistFileCmd)
101  DMXRun->SetsavehistFile(newValue);
102 
103 
104 }
void SetsavepmtFile(G4String val)
Definition: DMXRunAction.hh:66
void SetsavehitsFile(G4String val)
Definition: DMXRunAction.hh:65
void SetsavehistFile(G4String val)
Definition: DMXRunAction.hh:67

Here is the call graph for this function:


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