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

#include <CexmcEventActionMessenger.hh>

Inheritance diagram for CexmcEventActionMessenger:
Collaboration diagram for CexmcEventActionMessenger:

Public Member Functions

 CexmcEventActionMessenger (CexmcEventAction *eventAction)
 
 ~CexmcEventActionMessenger ()
 
void SetNewValue (G4UIcommand *cmd, G4String value)
 
- 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 CexmcEventActionMessenger.hh.

Constructor & Destructor Documentation

CexmcEventActionMessenger::CexmcEventActionMessenger ( CexmcEventAction eventAction)
explicit

Definition at line 50 of file CexmcEventActionMessenger.cc.

51  :
52  eventAction( eventAction ), setVerboseLevel( NULL ),
53  setVerboseDrawLevel( NULL )
54 {
55  setVerboseLevel = new G4UIcmdWithAnInteger(
56  ( CexmcMessenger::eventDirName + "verbose" ).c_str() , this );
57  setVerboseLevel->SetGuidance( "\n 0 - do not print messages,\n"
58  " 1 - print messages if studied interaction "
59  "triggered,\n"
60  " 2 - print messages on event trigger\n"
61  " (reconstructed data will also be printed in "
62  "this case),\n"
63  " 3 - print messages if studied interaction or "
64  "event\n triggered,\n"
65  " 4 - print messages on every event" );
66  setVerboseLevel->SetParameterName( "Verbose", false );
67  setVerboseLevel->SetRange( "Verbose >= 0 && Verbose <= 4" );
68  setVerboseLevel->SetDefaultValue( 0 );
69  setVerboseLevel->AvailableForStates( G4State_PreInit, G4State_Idle );
70 
71  setVerboseDrawLevel = new G4UIcmdWithAnInteger(
72  ( CexmcMessenger::visDirName + "verbose" ).c_str() , this );
73  setVerboseDrawLevel->SetGuidance( "\n 0 - draw nothing,\n"
74  " 1 - draw trajectories and track points if studied "
75  "interaction\n triggered,\n"
76  " 2 - draw trajectories and track points on event "
77  "trigger\n"
78  " (reconstructed data will also be drawn in "
79  "this case),\n"
80  " 3 - draw trajectories and track points if "
81  "studied interaction\n or event "
82  "triggered,\n"
83  " 4 - draw trajectories and/or track points on "
84  "every event" );
85  setVerboseDrawLevel->SetParameterName( "VerboseDraw", false );
86  setVerboseDrawLevel->SetRange( "VerboseDraw >= 0 && VerboseDraw <= 4" );
87  setVerboseDrawLevel->SetDefaultValue( 4 );
88  setVerboseDrawLevel->AvailableForStates( G4State_PreInit, G4State_Idle );
89 }
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
void SetRange(const char *rs)
Definition: G4UIcommand.hh:125
void SetGuidance(const char *aGuidance)
Definition: G4UIcommand.hh:161
void AvailableForStates(G4ApplicationState s1)
Definition: G4UIcommand.cc:240
static G4String visDirName
void SetDefaultValue(G4int defVal)
static G4String eventDirName

Here is the call graph for this function:

CexmcEventActionMessenger::~CexmcEventActionMessenger ( )

Definition at line 92 of file CexmcEventActionMessenger.cc.

93 {
94  delete setVerboseLevel;
95  delete setVerboseDrawLevel;
96 }

Member Function Documentation

void CexmcEventActionMessenger::SetNewValue ( G4UIcommand cmd,
G4String  value 
)
virtual

Reimplemented from G4UImessenger.

Definition at line 99 of file CexmcEventActionMessenger.cc.

101 {
102  do
103  {
104  if ( cmd == setVerboseLevel )
105  {
106  eventAction->SetVerboseOnCexmcLevel(
108  break;
109  }
110  if ( cmd == setVerboseDrawLevel )
111  {
112  eventAction->SetVerboseDrawLevel(
114  break;
115  }
116  } while ( false );
117 }
static G4int GetNewIntValue(const char *paramString)
void SetVerboseOnCexmcLevel(G4int value)
void SetVerboseDrawLevel(G4int value)

Here is the call graph for this function:


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