zeus::TArgumentParser Class Reference
#include <ArgumentParser.h>
List of all members.
Detailed Description
The argument parser parses the input parameters of an application (command line parameters). It groups them into param=value pairs.
Constructor & Destructor Documentation
| TArgumentParser::TArgumentParser |
( |
Int |
iArgC, |
|
|
char * |
apArgs[] | |
|
) |
| | |
Creates an argument parser. The arguments are stored in a char* array. This constructor is normaly used to parse arguments from an application
- Parameters:
-
| iArgC | : Number of arguments |
| apArgs,: | Array of arguments |
| TArgumentParser::TArgumentParser |
( |
const IString & |
rInParams |
) |
|
Creates an argument parser. The arguments are passed as a string. Note that the delimiter is a simple space
- Parameters:
-
| rInParams | : String containing all arguments (space seperated) |
| TArgumentParser::~TArgumentParser |
( |
|
) |
[protected, virtual] |
Destroys the argument parser
Member Function Documentation
| bool zeus::TArgumentParser::hasArgument |
( |
const IString & |
rArgName |
) |
const [inline] |
checks if an argument has been passed.
- Parameters:
-
| rArgName | : Name of the argument |
- Return values:
-
| true | : Argument has been passed |
| false | : No such argument found |
| bool zeus::TArgumentParser::hasArgument |
( |
const wchar_t * |
pArgName |
) |
const [inline] |
checks if an argument has been passed.
- Parameters:
-
| pArgName | : Name of the argument |
- Return values:
-
| true | : Argument has been passed |
| false | : No such argument found |
| bool zeus::TArgumentParser::hasArgumentWithValue |
( |
const IString & |
rArgName |
) |
const [inline] |
checks if an argument has been passed with a non empty value.
- Parameters:
-
| pArgName | : Name of the argument |
- Return values:
-
| true | : Argument has been passed |
| false | : No such argument found |
| bool zeus::TArgumentParser::hasArgumentWithValue |
( |
const wchar_t * |
pArgName |
) |
const [inline] |
checks if an argument has been passed with a non empty value.
- Parameters:
-
| pArgName | : Name of the argument |
- Return values:
-
| true | : Argument has been passed |
| false | : No such argument found |
| TString zeus::TArgumentParser::getArgumentValue |
( |
const IString & |
rArgName |
) |
const [inline] |
Returns the argument value if available
- Parameters:
-
| rArgName | : Name of the argument |
- Returns:
- Argument value
| TString zeus::TArgumentParser::getArgumentValue |
( |
const wchar_t * |
pArgName |
) |
const [inline] |
Returns the argument value if available
- Parameters:
-
| pArgName | : Name of the argument |
- Returns:
- Argument value
| TString zeus::TArgumentParser::getArgumentValueByIndex |
( |
Int |
iIndex |
) |
const [inline] |
Returns the argument value by index
- Parameters:
-
| iIndex | : Index of the argument |
- Returns:
- Argument value
| Int zeus::TArgumentParser::getArgumentCount |
( |
|
) |
const [inline] |
Returns the number of arguments
| TString zeus::TArgumentParser::getApplicationFile |
( |
|
) |
const [inline] |
Returns the file name of the application
| TString TArgumentParser::getApplicationMainPath |
( |
|
) |
const |
Returns the path of the application
| void zeus::TArgumentParser::resetList |
( |
|
) |
[inline] |
| TString zeus::TArgumentParser::getNextItem |
( |
|
) |
const [inline] |
returns the next argument name of the list
| bool zeus::TArgumentParser::hasNextItem |
( |
|
) |
const [inline] |
checks if there are more arguments
Member Data Documentation
Map of all parsed name-value pairs.
List of items to check the order.
The documentation for this class was generated from the following files: