ALib C++ Framework
by
Library Version: 2605 R0
Documentation generated by doxygen
Loading...
Searching...
No Matches
alib::app::ExitCodeDecl Class Reference

Description:

An exit-code of a cli application.

Construction is done by passing a custom enum element of an enum type equipped with ALib Enum Records of type ERExitCodeDecl.

When bootstrapping, the method void DefineExitCodes()  has to be invoked for (each) enum type.

With the announcment of exit codes to the CLI, these codes can be listed with help output generated by class CLIUtil.

Definition at line 556 of file cliargtypes.hpp.

#include <cliargtypes.hpp>

Collaboration diagram for alib::app::ExitCodeDecl:
[legend]

Public Method Index:

template<typename TEnum>
 ExitCodeDecl (TEnum element)
const StringFormatString ()
const StringName ()

Protected Field Index:

Enum declElement
 The enumeration element given with construction.
ERExitCodeDecl record
 A copy (!) of the enum record.
ResourceInfo resourceInfo
 The resource information of the enumeration type given with construction.

Field Details:

◆ declElement

Enum alib::app::ExitCodeDecl::declElement
protected

The enumeration element given with construction.

Definition at line 559 of file cliargtypes.hpp.

◆ record

ERExitCodeDecl alib::app::ExitCodeDecl::record
protected

A copy (!) of the enum record.

Definition at line 562 of file cliargtypes.hpp.

◆ resourceInfo

ResourceInfo alib::app::ExitCodeDecl::resourceInfo
protected

The resource information of the enumeration type given with construction.

Definition at line 565 of file cliargtypes.hpp.

Constructor(s) / Destructor Details:

◆ ExitCodeDecl()

template<typename TEnum>
alib::app::ExitCodeDecl::ExitCodeDecl ( TEnum element)
inline

Templated constructor which takes an enum element of a custom type equipped with ALib Enum Records of type ERExitCodeDecl.

Template Parameters
TEnumC++ enum type equipped with corresponding ALib Enum Records.
Parameters
elementThe enum element.

Definition at line 574 of file cliargtypes.hpp.

Here is the call graph for this function:

Method Details:

◆ FormatString()

const String & alib::app::ExitCodeDecl::FormatString ( )
inline

Returns the format string associated with this exit-code. Loads the string from resourceInfo using resource name "TExitNN", where NN is the enum element's integral value.

Returns
The format string.

Definition at line 590 of file cliargtypes.hpp.

◆ Name()

const String & alib::app::ExitCodeDecl::Name ( )
inline

Returns the name of the enum element

Returns
The name of the enum element.

Definition at line 584 of file cliargtypes.hpp.


The documentation for this class was generated from the following file: