ALib C++ Library
Library Version: 2511 R0
Documentation generated by doxygen
Loading...
Searching...
No Matches
alib::cli::Parameter Struct Reference

Description:

A declaration for a cli::Parameter.

Definition at line 181 of file arguments.inl.

Inheritance diagram for alib::cli::Parameter:
[legend]
Collaboration diagram for alib::cli::Parameter:
[legend]

Public Field Index:

ListMA< String, Recycling::Shared > Args
 Arguments belonging to us.
 
ParameterDeclDeclaration = nullptr
 The underlying declaration.
 
- Public Field Index: inherited from alib::cli::Parsed
CommandLineCmdLine
 The cli command line.
 
integer ConsumedArguments
 
integer Position
 

Public Method Index:

 Parameter (CommandLine *cmdLine)
 
ALIB_DLL bool Read (ParameterDecl &decl)
 
- Public Method Index: inherited from alib::cli::Parsed
 Parsed (CommandLine *cmdLine)
 

Field Details:

◆ Args

ListMA<String, Recycling::Shared> alib::cli::Parameter::Args

Arguments belonging to us.

Definition at line 187 of file arguments.inl.

◆ Declaration

ParameterDecl* alib::cli::Parameter::Declaration = nullptr

The underlying declaration.

Definition at line 184 of file arguments.inl.

Constructor(s) / Destructor Details:

◆ Parameter()

alib::cli::Parameter::Parameter ( CommandLine * cmdLine)
inline

Constructor

Parameters
cmdLineThe command line instance.

Definition at line 460 of file commandline.inl.

Here is the call graph for this function:

Method Details:

◆ Read()

bool alib::cli::Parameter::Read ( ParameterDecl & decl)

Tries to read the object from the front of CommandLine::ArgsLeft. Success is indicated by setting inherited fields Parsed::Position and Parsed::ConsumedArguments to values greater than 0.

If it could not be decided if the actual CLI argument contains this parameter, false is returned to indicate that parsing commands has to stop now.

This is done in the following cases:

See ReadNextCommands for details

Parameters
declThe declaration used for reading
Returns
The true on success, false indicates that parsing has to end here.

Definition at line 203 of file arguments.cpp.

Here is the call graph for this function:

The documentation for this struct was generated from the following files: