GGS(GenericGEANT4Simulation)Software  2.7.0
 All Data Structures Namespaces Files Functions Variables Typedefs Macros
Public Member Functions
GGSHadrIntMessenger Class Reference

A control messenger for GGSHadrIntAction. More...

#include <GGSHadrIntMessenger.h>

Inheritance diagram for GGSHadrIntMessenger:
Inheritance graph
[legend]
Collaboration diagram for GGSHadrIntMessenger:
Collaboration graph
[legend]

Public Member Functions

 GGSHadrIntMessenger (GGSHadrIntAction *action)
 Constructor.
 
 ~GGSHadrIntMessenger ()
 Destructor.
 
void SetNewValue (G4UIcommand *command, G4String newValue)
 Override of SetNewValue method. More...
 

Detailed Description

A control messenger for GGSHadrIntAction.

This messenger controls the GGSHadrIntAction action. The construction and destruction of this messenger is handled by GGSHadrIntAction itself, so messenger's commands will be available as the action is built. Currently, the available commands are:

/GGS/userActions/hadrIntAction/fileBase: sets the output file base name. /GGS/userActions/hadrIntAction/treeName: sets the output tree name. /GGS/userActions/hadrIntAction/energyFraction: sets the energy fraction for quasi-elastic interactions tagging. /GGS/userActions/hadrIntAction/outProducts: toggles on and off saving interaction products.

See Also
GGSHadrIntAction

Definition at line 34 of file GGSHadrIntMessenger.h.

Member Function Documentation

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

Override of SetNewValue method.

Parameters
commandThe UI command.
newValueThe new value to be set.

Definition at line 56 of file GGSHadrIntMessenger.cpp.

56  {
57 
58  if (command == _outBaseCmd)
59  _action->SetOutputFileBase(newValue);
60 
61  if (command == _outTreeCmd)
62  _action->SetOutputTreeName(newValue);
63 
64  if (command == _setFractionCmd)
65  _action->SetEnergyFraction(_setFractionCmd->GetNewDoubleValue(newValue));
66 
67  if (command == _outProductsCmd) {
68  _action->SetOutputOfProducts(_outProductsCmd->GetNewBoolValue(newValue));
69  }
70 }
void SetOutputFileBase(const std::string &outFileBase)
Sets the output file base name.
void SetOutputTreeName(const std::string &outTreeName)
Sets the output tree name.
void SetOutputOfProducts(bool output)
Toggles the output of hadronic interaction products.
void SetEnergyFraction(double fraction)
Sets the maximum secondary energy fraction for hadronic interactions.

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