|
Geant4 examples
|
Messenger class that defines commands for B4bEventAction class. More...
#include <Doxymodules_basic.h>
Public Member Functions | |
| B4bEventActionMessenger (B4bEventAction *eventAction) | |
| virtual | ~B4bEventActionMessenger () |
| virtual void | SetNewValue (G4UIcommand *command, G4String value) |
Private Attributes | |
| B4bEventAction * | fEventAction |
| G4UIdirectory * | fDirectory |
| G4UIcmdWithAnInteger * | fSetPrintModuloCmd |
Messenger class that defines commands for B4bEventAction class.
It implements commands:
Definition at line 117 of file Doxymodules_basic.h.
| B4bEventActionMessenger::B4bEventActionMessenger | ( | B4bEventAction * | eventAction | ) |
Definition at line 39 of file B4bEventActionMessenger.cc.
: G4UImessenger(), fEventAction(eventAction), fDirectory(0), fSetPrintModuloCmd(0) { fDirectory = new G4UIdirectory("/B4/event/"); fDirectory->SetGuidance("event control"); fSetPrintModuloCmd = new G4UIcmdWithAnInteger("/B4/event/setPrintModulo",this); fSetPrintModuloCmd->SetGuidance("Print events modulo n"); fSetPrintModuloCmd->SetParameterName("EventNb",false); fSetPrintModuloCmd->SetRange("EventNb>0"); }
| B4bEventActionMessenger::~B4bEventActionMessenger | ( | ) | [virtual] |
Definition at line 57 of file B4bEventActionMessenger.cc.
{
delete fSetPrintModuloCmd;
delete fDirectory;
}
| void B4bEventActionMessenger::SetNewValue | ( | G4UIcommand * | command, |
| G4String | value | ||
| ) | [virtual] |
Reimplemented from G4UImessenger.
Definition at line 65 of file B4bEventActionMessenger.cc.
{
if ( command == fSetPrintModuloCmd ) {
fEventAction->SetPrintModulo(fSetPrintModuloCmd->GetNewIntValue(newValue));
}
}
Definition at line 55 of file B4bEventActionMessenger.hh.
G4UIdirectory* B4bEventActionMessenger::fDirectory [private] |
Definition at line 56 of file B4bEventActionMessenger.hh.
Definition at line 57 of file B4bEventActionMessenger.hh.
1.7.4