138 template<
typename TEnum>
146 if(
record.valueListSeparator ==
'C' )
147 record.valueListSeparator=
',';
180 {
return record.valueListSeparator !=
'C' ?
record.valueListSeparator :
','; }
301 template<
typename TEnum>
326 return record.identifierChar.IsNotEmpty() ?
record.identifierChar.CharAtStart()
451 template<
typename TEnum>
492 void addParamDecls();
573 template<
typename TEnum>
CommandLine & CmdLine
The command-line instance we belong to.
const String & HelpTextLong()
const String & HelpTextShort()
ListMA< ParameterDecl * > Parameters
Command parameters.
ERCommandDecl record
A copy (!) of the enum record.
int MinimumRecognitionLength()
const Enum & Element() const
CommandDecl(TEnum element, CommandLine &cmdLine)
ResourceInfo resourceInfo
The resource information of the enumeration type given with construction.
const String & Identifier()
Enum declElement
The enumeration element given with construction.
const String & FormatString()
ResourceInfo resourceInfo
The resource information of the enumeration type given with construction.
Enum declElement
The enumeration element given with construction.
ExitCodeDecl(TEnum element)
ERExitCodeDecl record
A copy (!) of the enum record.
EROptionDecl record
A copy (!) of the enum record.
character IdentifierChar()
integer QtyExpectedArgsFollowing()
Enum declElement
The enumeration element given with construction.
ResourceInfo resourceInfo
The resource information of the enumeration type given with construction.
const String & HelpUsageLine()
const Enum & Element() const
const String & Identifier()
OptionDecl(TEnum element)
int MinimumRecognitionLength()
const String & HelpText()
const String & ValueSeparator()
const String & ShortcutReplacementString()
int MinimumRecognitionLength()
const String & ValueSeparator()
Enum declElement
The enumeration element given with construction.
const String & Identifier()
const Enum & Element() const
nchar ValueListSeparator()
const String & GetHelpTextShort()
ERParameterDecl record
A copy (!) of the enum record.
const String & GetHelpTextLong()
ParameterDecl(TEnum element)
int QtyExpectedArgsFollowing()
ResourceInfo resourceInfo
The resource information of the enumeration type given with construction.
@ IllegalOptionNameContinuation
@ ParsingOptions
General option parse error. Adds option help text.
@ ParsingCommand
General parameter parse error. Adds command help text.
@ NoCommandGiven
Unknown command given.
@ UnknownCommand
Unknown command given.
const RecordsTraits< TEnum >::Type & GetRecord(TEnum element)
containers::List< T, MonoAllocator, TRecycling > ListMA
Type alias in namespace #"%alib".
LocalString< 64 > String64
Type alias name for #"TLocalString;TLocalString<character,64>".
lang::integer integer
Type alias in namespace #"%alib".
strings::TString< character > String
Type alias in namespace #"%alib".
characters::nchar nchar
Type alias in namespace #"%alib".
resources::ResourceInfo ResourceInfo
Type alias in namespace #"%alib".
characters::character character
Type alias in namespace #"%alib".
NLocalString< 64 > NString64
Type alias name for #"TLocalString;TLocalString<nchar,64>".
boxing::Enum Enum
Type alias in namespace #"%alib".
CommandDecl * Declaration
The underlying declaration.
ListMA< Parameter *, Recycling::Shared > ParametersMandatory
Mandatory parameters parsed.
ListMA< Parameter *, Recycling::Shared > ParametersOptional
Optional parameters parsed.
Parameter * GetParsedParameter(const String &name)
String GetParsedParameterArg(const String &name)
bool Read(CommandDecl &decl)
Command(CommandLine *cmdLine)
#"alib_enums_records;ALib Enum Record" type used by class #"CommandDecl".
ERCommandDecl() noexcept=default
String parameters
List of parameters attached. Separated by '/'.
void Parse()
Implementation of #"EnumRecordPrototype::Parse;*".
ERExitCodeDecl() noexcept
#"alib_enums_records;ALib Enum Record" type used by class #"OptionDecl".
void Parse()
Implementation of #"EnumRecordPrototype::Parse;*".
String shortcutReplacementString
EROptionDecl() noexcept=default
integer RequiredArguments
#"alib_enums_records;ALib Enum Record" type used by class #"ParameterDecl".
ERParameterDecl() noexcept=default
String identifier
The identifier of the parameter.
bool isOptional
Denotes if this is an optional parameter.
void Parse()
Implementation of #"EnumRecordPrototype::Parse;*".
bool Read(OptionDecl &decl, String &arg, const integer argNo)
ListMA< String, Recycling::Shared > Args
Arguments belonging to this option.
OptionDecl * Declaration
The declaration struct.
Option(CommandLine *cmdLine)
A declaration for a #"app::Parameter".
bool Read(ParameterDecl &decl)
ListMA< String, Recycling::Shared > Args
Arguments belonging to us.
ParameterDecl * Declaration
The underlying declaration.
Parameter(CommandLine *cmdLine)
integer ConsumedArguments
CommandLine * CmdLine
The cli command-line.
Parsed(CommandLine *cmdLine)
ERSerializable() noexcept=default
Defaulted constructor leaving the record undefined.