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);
127 std::map<G4String, Command*> fCommandMap;
129 G4int fMaxMarkerLength;
130 G4int fMaxOptionNameLength;
int Parse(int &argc, char **argv)
virtual const G4String & GetDefaultOption()
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 * GetParser()
virtual const G4String & GetOption()
static G4String fNoOption
virtual void SetOptionName(const G4String &)
static void DeleteInstance()
virtual const G4String & GetOptionName()
virtual const G4String & GetDefaultOption()
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()