OpenASIP 2.2
|
#include <CmdLineOptionParser.hh>
Public Member Functions | |
UnsignedIntegerCmdLineOptionParser (std::string name, std::string desc, std::string alias="") | |
virtual | ~UnsignedIntegerCmdLineOptionParser () |
virtual OptionValue * | copy () const |
virtual bool | parseValue (std::string arguments, std::string prefix) |
virtual unsigned | unsignedInteger (int index=0) const |
![]() | |
CmdLineOptionParser (std::string name, std::string desc, std::string alias, bool hidden=false) | |
virtual | ~CmdLineOptionParser () |
std::string | longName () const |
std::string | shortName () const |
std::string | description () const |
bool | isHidden () |
bool | isDefined () |
virtual int | integer (int index=0) const |
virtual std::string | String (int index=0) const |
virtual double | real () const |
virtual bool | isFlagOn () const |
virtual bool | isFlagOff () const |
virtual int | listSize () const |
Private Member Functions | |
UnsignedIntegerCmdLineOptionParser (const UnsignedIntegerCmdLineOptionParser &) | |
Copying not allowed. | |
UnsignedIntegerCmdLineOptionParser & | operator= (const UnsignedIntegerCmdLineOptionParser &) |
Assignment not allowed. | |
Private Attributes | |
unsigned | value_ |
The value of option. | |
Additional Inherited Members | |
![]() | |
void | setDefined () |
Models an option that has an unsigned integer value.
Definition at line 147 of file CmdLineOptionParser.hh.
UnsignedIntegerCmdLineOptionParser::UnsignedIntegerCmdLineOptionParser | ( | std::string | name, |
std::string | desc, | ||
std::string | alias = "" |
||
) |
Constructor.
name | The name of the option. |
desc | The description of the option. |
alias | The short name of the option. |
Definition at line 269 of file CmdLineOptionParser.cc.
|
virtual |
|
private |
Copying not allowed.
|
virtual |
Implements CmdLineOptionParser.
Definition at line 283 of file CmdLineOptionParser.cc.
References copy(), and value_.
Referenced by copy().
|
private |
Assignment not allowed.
|
virtual |
Parses the unsigned integer option value.
arguments | The arguments of option. |
prefix | The prefix of option. |
IllegalCommandLine | If the arguments of option are erronous. |
Implements CmdLineOptionParser.
Definition at line 297 of file CmdLineOptionParser.cc.
References CmdLineOptionParser::longName(), CmdLineOptionParser::setDefined(), and value_.
|
virtual |
Returns the value of the unsigned integer option.
index | This must be zero for usigned integer option. |
WrongSubclass | Is never thrown by this function. |
Reimplemented from CmdLineOptionParser.
Definition at line 331 of file CmdLineOptionParser.cc.
|
private |
The value of option.
Definition at line 169 of file CmdLineOptionParser.hh.
Referenced by copy(), parseValue(), and unsignedInteger().