LibCppCmd v1.0 Beta 15
C++ Command Line Parsing Library
|
This Definition is used to construct an Option. More...
#include <Option.h>
Public Attributes | |
char | shortName = 0 |
The short name of the Option. | |
std::string | longName |
The long name of the Option. | |
std::string | description |
The description of the Option. | |
bool | isMandatory = false |
Determines whether the Option is mandatory. | |
Style | style = Style::Unix |
Determines the Option::Style of the option. | |
This Definition is used to construct an Option.
An Option::Definition is passed to the constructor of a new Option to specify its attributes.
std::string CmdLine::Option::Definition::description |
The description of the Option.
bool CmdLine::Option::Definition::isMandatory = false |
Determines whether the Option is mandatory.
std::string CmdLine::Option::Definition::longName |
The long name of the Option.
The longName of an Option is a sequence of characters representing the Option. Depending on the Option::Style used, the Option will automatically add the appropreate prefix (– for Options with the Unix style and / for Options with the Windows style). If the longName is "print", an Option with the Unix style will be specified by the "--print" argument at the CommandLine and an Option with the Windows style will be specified by the "/print" argument.
char CmdLine::Option::Definition::shortName = 0 |
The short name of the Option.
The shortName of an Option is just a single character representing the Option. Depending on the Option::Style used, the Option will automatically add the appropreate prefix (- for Options with the Unix style and / for Options with the Windows style). If the shortName is 'p', an Option with the Unix style will be specified by the "-p" argument at the command line and an Option with the Windows style will be specified by the "/p" argument.
Style CmdLine::Option::Definition::style = Style::Unix |
Determines the Option::Style of the option.