39 #ifdef G4MULTITHREADED
54 #include "ActionInitialization.hh"
55 #include "DetectorConstruction.hh"
56 #include "PhysicsList.hh"
57 #include "CommandLineParser.hh"
61 using namespace G4DNAPARSER;
64 void Parse(
int& argc,
char** argv);
66 int main(
int argc,
char** argv)
81 #ifdef G4MULTITHREADED
94 G4cout <<
"===== Microdosimetry is started with "
96 <<
" threads =====" <<
G4endl;
170 G4String command =
"/control/execute ";
175 UImanager->
ApplyCommand(
"/control/execute microdosimetry.in");
181 G4UIQt* UIQt =
static_cast<G4UIQt*
> (UImanager->
GetG4UIWindow());
183 UIQt->AddViewerTabFromFile(
"README",
"README from "+
G4String(argv[0]));
203 std::string aux(argv[0]);
206 #if defined(_WIN32) || defined(WIN32)
207 int pos = aux.rfind(
'\\');
209 int pos = aux.rfind(
'/');
213 path = aux.substr(0, pos + 1);
214 executable = aux.substr(pos + 1);
219 void Parse(
int& argc,
char** argv)
228 "Select geant4 UI or just launch a geant4 terminal session",
233 "Give a mac file to execute",
242 #ifdef G4MULTITHREADED
245 "Launch in MT mode (events computed in parallel)",
251 "Select a visualization driver",
256 "Deactivate visualization when using GUI");
void Parse(int &argc, char **argv)
virtual const G4String & GetOption()
void SetNumberOfThreads(G4int n)
static CommandLineParser * GetParser()
static const G4double pos
G4int ApplyCommand(const char *aCommand)
G4UIsession * GetG4UIWindow() const
int Parse(int &argc, char **argv)
G4int G4GetNumberOfCores()
static G4UImanager * GetUIpointer()
G4int GetNumberOfThreads() const
static G4int ConvertToInt(const char *st)
virtual void SetUserInitialization(G4VUserDetectorConstruction *userInit)
Action initialization class.
CommandLineParser * parser(0)
int main(int argc, char **argv)
void GetNameAndPathOfExecutable(char **argv, G4String &executable, G4String &path)
Command * GetCommandIfActive(const G4String &marker)
static void DeleteInstance()
G4GLOB_DLL std::ostream G4cout
bool CheckIfNotHandledOptionsExists(int &argc, char **argv)
void AddCommand(const G4String &marker, Command::Type, const G4String &description="", const G4String &defaultOption="", const G4String &optionName="")
virtual void Initialize()
Simple detector construction with a box volume placed in a world.