|
QuasarAppLib 1.0.530.c9fba11
|
The OptionData class contains information about one option. More...
#include <optiondata.h>

Public Member Functions | |
| OptionData (const QStringList &names, const QString &arguments="", const QString &description="", const QString &example="", const QString &deprecatedMsg="", bool removed=false) | |
| OptionData This is main constructor. | |
| const QStringList & | names () const |
| name This is name of the option. It is a required argument and cannot be empty. | |
| const QString & | description () const |
| description This is description message of this option. | |
| const QString & | example () const |
| example This is example of use string. | |
| const QString & | arguments () const |
| arguments This is input arguments of this option or help message about arguments. | |
| const QString & | deprecatedMsg () const |
| deprecatedWarning This is a message that will be printed as a warning if user will use this option. If you set this argument to empty value then warning message will be ignored and option not be marked asa a deprecated. An option will be marked as a deprecated when this arguments will not equal empty string. | |
| Help::Options | toHelp () const |
| toHelp This method convert this option into help line. The help line have next structure : | |
| bool | isValid () const |
| isValid This method return true if the option is valid. If option do not contain a name then it is invalid. | |
| bool | isRemoved () const |
| isRemoved This method return true if the option is removed. | |
| bool | isDeprecated () const |
| isDeprecated This method return true if this option is deprecated. | |
Protected Member Functions | |
| void | setNames (const QStringList &newNames) |
| setNames This method sets new value of the option name. | |
| void | setDescription (const QString &newDescription) |
| setDescription This method sets new description of this options. | |
| void | setExample (const QString &newExample) |
| setExample This method sets a new example value of this option | |
| void | setArguments (const QString &newArguments) |
| setArguments This method sets new value of the options arguments | |
| void | setDeprecatedMsg (const QString &newDeprecatedMsg) |
| setDeprecatedMsg This method sets new value of the deprecated warning message of this option. | |
The OptionData class contains information about one option.
Definition at line 20 of file optiondata.h.
| QuasarAppUtils::OptionData::OptionData | ( | const QStringList & | names, |
| const QString & | arguments = "", | ||
| const QString & | description = "", | ||
| const QString & | example = "", | ||
| const QString & | deprecatedMsg = "", | ||
| bool | removed = false ) |
OptionData This is main constructor.
| names | This is names list of the option. It is a required argument and cannot be empty. |
| arguments | This is input arguments of this option or help message about arguments. |
| description | This is description message of this option. |
| example | This is example of use string. |
| deprecatedMsg | This is a message that will be printed as a warning if user will use this option. If you set this argument to empty value then warning message will be ignored and option not be marked asa a deprecated. An option will be marked as a deprecated when this arguments will not equal empty string. |
| removed | This option show deprecatedMsg as a error and force the parseParams method return false. This option will be ignored if the deprecatedMsg will be empty. |
Definition at line 13 of file optiondata.cpp.

| const QString & QuasarAppUtils::OptionData::arguments | ( | ) | const |
arguments This is input arguments of this option or help message about arguments.
Definition at line 52 of file optiondata.cpp.

| const QString & QuasarAppUtils::OptionData::deprecatedMsg | ( | ) | const |
deprecatedWarning This is a message that will be printed as a warning if user will use this option. If you set this argument to empty value then warning message will be ignored and option not be marked asa a deprecated. An option will be marked as a deprecated when this arguments will not equal empty string.
Definition at line 60 of file optiondata.cpp.

| const QString & QuasarAppUtils::OptionData::description | ( | ) | const |
description This is description message of this option.
Definition at line 36 of file optiondata.cpp.

| const QString & QuasarAppUtils::OptionData::example | ( | ) | const |
example This is example of use string.
Definition at line 44 of file optiondata.cpp.

| bool QuasarAppUtils::OptionData::isDeprecated | ( | ) | const |
isDeprecated This method return true if this option is deprecated.
Definition at line 72 of file optiondata.cpp.

| bool QuasarAppUtils::OptionData::isRemoved | ( | ) | const |
isRemoved This method return true if the option is removed.
Definition at line 68 of file optiondata.cpp.
| bool QuasarAppUtils::OptionData::isValid | ( | ) | const |
isValid This method return true if the option is valid. If option do not contain a name then it is invalid.
Definition at line 87 of file optiondata.cpp.

| const QStringList & QuasarAppUtils::OptionData::names | ( | ) | const |
name This is name of the option. It is a required argument and cannot be empty.
Definition at line 28 of file optiondata.cpp.

|
protected |
setArguments This method sets new value of the options arguments
| newArguments | new value of the options arguments |
Definition at line 56 of file optiondata.cpp.

|
protected |
setDeprecatedMsg This method sets new value of the deprecated warning message of this option.
| newDeprecatedMsg | This is new value of the deprecated message. |
Definition at line 64 of file optiondata.cpp.

|
protected |
setDescription This method sets new description of this options.
| newDescription | This is new value of options description |
Definition at line 40 of file optiondata.cpp.

|
protected |
setExample This method sets a new example value of this option
| newExample | This is a new value of the options example. |
Definition at line 48 of file optiondata.cpp.

|
protected |
setNames This method sets new value of the option name.
| newNames | This is a new value of the options name. |
Definition at line 32 of file optiondata.cpp.

| Help::Options QuasarAppUtils::OptionData::toHelp | ( | ) | const |
toHelp This method convert this option into help line. The help line have next structure :
Key: {name [arguments]} Value: {description examples}
Definition at line 76 of file optiondata.cpp.
