Public Member Functions | |
OtherOptionArg () | |
virtual | ~OtherOptionArg () |
virtual std::string | getHelp () const |
The help message given for the option. | |
virtual bool | argMatch () |
Returns true if the argument matches the option flag. | |
virtual bool | parseArg () |
The method to parse the arguments. | |
virtual int | nbPresent () const |
Returns the number of time when the option flag is present in the command line. |
Definition at line 11 of file OBTOptionArg.cpp.
OBT::OtherOptionArg::OtherOptionArg | ( | ) | [inline] |
Definition at line 14 of file OBTOptionArg.cpp.
00014 : OptionArg( "", "" ) {}
virtual OBT::OtherOptionArg::~OtherOptionArg | ( | ) | [inline, virtual] |
Definition at line 15 of file OBTOptionArg.cpp.
virtual bool OBT::OtherOptionArg::argMatch | ( | ) | [inline, virtual] |
Returns true if the argument matches the option flag.
Reimplemented from OBT::OptionArg.
Definition at line 17 of file OBTOptionArg.cpp.
virtual std::string OBT::OtherOptionArg::getHelp | ( | ) | const [inline, virtual] |
The help message given for the option.
Returns the option flag following by the help message.
Reimplemented from OBT::OptionArg.
Definition at line 16 of file OBTOptionArg.cpp.
virtual int OBT::OtherOptionArg::nbPresent | ( | ) | const [inline, virtual] |
Returns the number of time when the option flag is present in the command line.
See _flag.
Reimplemented from OBT::OptionArg.
Definition at line 19 of file OBTOptionArg.cpp.
References OBT::OptionArgHandler::_optionList, and OBT::OptionArgHandler::get().
00020 { 00021 int nb = 0 ; 00022 const ListArg& optionList = OptionArgHandler::get()._optionList ; 00023 for( ListArg::const_iterator option = optionList.begin() ; 00024 option != optionList.end() ; 00025 option++ ) 00026 { 00027 nb += ( (*option) != this ) && (*option)->isPresent() ? 1 : 0 ; 00028 } 00029 return nb ; 00030 }
virtual bool OBT::OtherOptionArg::parseArg | ( | ) | [inline, virtual] |
The method to parse the arguments.
Retrieves the argument which can be following the option flag. See OptionFlag::parseArg, OptionNPrm::parseArg, OptionMultiNPrm::parseArg for examples.
Implements OBT::OptionArg.
Definition at line 18 of file OBTOptionArg.cpp.