#include <G4PersistencyCenterMessenger.hh>
Definition at line 34 of file G4PersistencyCenterMessenger.cc.
37 std::string
name =
"/persistency/";
39 directory->
SetGuidance(
"Control commands for Persistency package");
41 std::string cmd = name +
"verbose";
44 verboseCmd->
SetGuidance(
"Set the verbose level of G4PersistencyManager.");
46 verboseCmd->
SetGuidance(
" 1 : Display main topics");
47 verboseCmd->
SetGuidance(
" 2 : Display event-level topics");
48 verboseCmd->
SetGuidance(
" 3 : Display debug information");
51 verboseCmd->
SetRange(
"level >=0 && level <=3");
53 std::string vname = name +
"select";
57 select->
SetGuidance(
"Selection of a persistency package");
61 vname = name +
"store/";
64 subdir1->
SetGuidance(
"Specifiy object types for store");
66 wrObj.push_back(
"HepMC");
67 wrObj.push_back(
"MCTruth");
68 wrObj.push_back(
"Hits");
73 for ( i = 0; i < 3; i++ )
75 cmd = vname + wrObj[i];
76 guidance =
"Store " + wrObj[i] +
" objects for output";
78 storeObj[i]->SetGuidance(guidance.c_str());
79 if ( wrObj[i] ==
"HepMC" ) {
80 storeObj[i]->SetCandidates(
"on off recycle");
82 storeObj[i]->SetCandidates(
"on off");
88 subdir2->
SetGuidance(
"Select I/O manager for store");
90 cmd = vname +
"hitIO";
95 vname = name +
"set/";
99 vname +=
"writeFile/";
101 subdir4->
SetGuidance(
"Set output file names for object types");
103 for ( i = 0; i < 3; i++ )
105 cmd = vname + wrObj[i];
106 guidance =
"Set an output file name for " + wrObj[i] +
".";
108 setWrFile[i]->SetGuidance(guidance.c_str());
109 setWrFile[i]->SetParameterName(
"file name",
true,
true);
112 vname = name +
"set/ReadFile/";
114 subdir5->
SetGuidance(
"Set input file names for object types");
116 rdObj.push_back(
"Hits");
118 cmd = vname + rdObj[0];
119 guidance =
"Set an input file name for " + rdObj[0] +
".";
121 setRdFile[0]->SetGuidance(guidance.c_str());
122 setRdFile[0]->SetParameterName(
"file name",
true,
true);
124 cmd = name +
"printall";
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
void SetParameterName(const char *theName, G4bool omittable, G4bool currentAsDefault=false)
void SetRange(const char *rs)
void SetGuidance(const char *aGuidance)
void SetCandidates(const char *candidateList)
void SetDefaultValue(G4int defVal)
G4PersistencyCenterMessenger::~G4PersistencyCenterMessenger |
( |
| ) |
|
Reimplemented from G4UImessenger.
Definition at line 203 of file G4PersistencyCenterMessenger.cc.
207 if (command==verboseCmd)
211 else if (command==select)
215 else if (command==regHitIO)
219 else if (command==setRdFile[0])
225 for(
int i=0; i<3; i++ ) {
226 if( command==storeObj[i] )
243 else if( command==setWrFile[i] )
std::string CurrentReadFile(std::string objName)
StoreMode CurrentStoreMode(std::string objName)
std::string CurrentHCIOmanager()
const std::string CurrentSystem()
std::string CurrentWriteFile(std::string objName)
Reimplemented from G4UImessenger.
Definition at line 152 of file G4PersistencyCenterMessenger.cc.
154 if (command==verboseCmd)
158 else if (command==select)
162 else if (command==regHitIO)
164 pc->
AddHCIOmanager(PopWord(newValues,1,
" "),PopWord(newValues,2,
" "));
166 else if (command==setRdFile[0])
168 pc -> SetReadFile ( rdObj[0],newValues);
170 else if (command==printAll)
176 for(
int i=0; i<3; i++ ) {
177 if( command==storeObj[i] )
180 if( newValues ==
"on" ) {
182 }
else if ( newValues ==
"off" ) {
184 }
else if ( newValues ==
"recycle" ) {
187 G4cerr <<
"Unrecognized keyword - \"" << newValues <<
"\"."
193 else if( command==setWrFile[i] )
void AddHCIOmanager(std::string detName, std::string colName)
static G4int GetNewIntValue(const char *paramString)
void SelectSystem(std::string systemName)
G4bool SetWriteFile(std::string objName, std::string writeFileName)
void SetStoreMode(std::string objName, StoreMode mode)
G4GLOB_DLL std::ostream G4cerr
void SetVerboseLevel(int v)
The documentation for this class was generated from the following files: