args-parser 6.3.3
|
Group of args where only one argument can be defined. More...
#include <groups.hpp>
Public Member Functions | |
template<typename T > | |
OnlyOneGroup (T &&name, bool required=false) | |
virtual | ~OnlyOneGroup () |
ArgType | type () const override |
bool | isDefined () const override |
Public Member Functions inherited from Args::GroupIface | |
template<typename T > | |
GroupIface (T &&name, bool required=false) | |
virtual | ~GroupIface () |
const Arguments & | children () const |
void | addArg (ArgIface &arg) |
Add argument. | |
void | addArg (ArgIface *arg) |
Add argument. | |
virtual void | addArg (ArgPtr arg) |
Add argument. | |
String | name () const override |
bool | isWithValue () const override |
bool | isRequired () const override |
virtual void | setRequired (bool on=true) |
Set required flag. | |
const String & | flag () const override |
const String & | argumentName () const override |
const String & | valueSpecifier () const override |
const String & | description () const override |
const String & | longDescription () const override |
void | clear () override |
Clear state of the argument. | |
Public Member Functions inherited from Args::ArgIface | |
ArgIface () | |
virtual | ~ArgIface () |
CmdLine * | cmdLine () const |
Protected Member Functions | |
void | checkCorrectnessBeforeParsing (StringList &flags, StringList &names) const override |
Check correctness of the argument before parsing. | |
void | checkCorrectnessAfterParsing () const override |
Check correctness of the argument after parsing. | |
Protected Member Functions inherited from Args::GroupIface | |
ArgIface * | findArgument (const String &name) override |
void | process (Context &) override |
Process argument's staff, for example take values from context. | |
void | setCmdLine (CmdLine *cmdLine) override |
Set command line parser. | |
bool | isMisspelledName (const String &name, StringList &possibleNames) const override |
Additional Inherited Members | |
Public Types inherited from Args::GroupIface | |
using | ArgPtr = std::unique_ptr< ArgIface, details::Deleter< ArgIface > > |
Smart pointer to the argument. | |
using | Arguments = std::vector< ArgPtr > |
List of child arguments. | |
Protected Attributes inherited from Args::GroupIface | |
Arguments | m_children |
List of children. | |
Group of args where only one argument can be defined.
Definition at line 55 of file groups.hpp.
|
inlineexplicit |
Definition at line 60 of file groups.hpp.
|
inlinevirtual |
Definition at line 66 of file groups.hpp.
|
inlineoverrideprotectedvirtual |
Check correctness of the argument after parsing.
Reimplemented from Args::GroupIface.
Definition at line 109 of file groups.hpp.
|
inlineoverrideprotectedvirtual |
Check correctness of the argument before parsing.
Implementation of this method must add his flag and name to the flags and names.
flags | All known flags. |
names | All known names. |
Reimplemented from Args::GroupIface.
Definition at line 90 of file groups.hpp.
|
inlineoverridevirtual |
Implements Args::ArgIface.
Definition at line 77 of file groups.hpp.
|
inlineoverridevirtual |