39 #ifndef COMMANDLINEPARSER_HH
40 #define COMMANDLINEPARSER_HH
80 class CommandWithOption :
public Command
96 const G4String &optionName =
"optionName");
105 class CommandLineParser
113 int Parse(
int& argc,
char **argv);
int Parse(int &argc, char **argv)
G4int fMaxOptionNameLength
virtual const G4String & GetDefaultOption()
CommandWithOption(Type, const G4String &description="", const G4String &defaultOption="", const G4String &optionName="optionName")
void AddCommand(const G4String &marker, Command::Type, const G4String &description="", const G4String &defaultOption="", const G4String &optionName="")
Command * GetCommandIfActive(const G4String &marker)
const G4String & GetDescription()
virtual void SetOption(const G4String &)
bool CheckIfNotHandledOptionsExists(int &argc, char **argv)
virtual void SetOption(const G4String &in_op)
static CommandLineParser * fpInstance
static CommandLineParser * GetParser()
virtual const G4String & GetOption()
static G4String fNoOption
virtual void SetOptionName(const G4String &)
static void DeleteInstance()
virtual const G4String & GetOptionName()
virtual const G4String & GetDefaultOption()
std::map< G4String, Command * > fCommandMap
virtual ~CommandWithOption()
virtual void SetDefaultOption(const G4String &in_op)
void CorrectRemainingOptions(int &argc, char **argv)
virtual void SetOptionName(const G4String &in_op)
Command(Type, const G4String &description="")
Command * FindCommand(const G4String &marker)
virtual void SetDefaultOption(const G4String &)
virtual const G4String & GetOption()
G4bool WereOptionsSetup()
virtual const G4String & GetOptionName()