|
cli11
|
Supplies the constructor set every error type shares. More...
Public Member Functions | |
| error_mixin_t (std::string msg, exit_codes_t exit_code) | |
Constructs the error, naming it from derived_t. | |
| error_mixin_t (std::string msg, int exit_code) | |
Constructs the error, naming it from derived_t. | |
Protected Member Functions | |
| error_mixin_t (std::string ename, std::string msg, int exit_code) | |
| Forwards an explicit type name, for further derivation. | |
| error_mixin_t (std::string ename, std::string msg, exit_codes_t exit_code) | |
| Forwards an explicit type name, for further derivation. | |
Supplies the constructor set every error type shares.
Each error type in the hierarchy needs the same four constructors: a protected pair taking an explicit type name, so that further derivation works, and a public pair that fills the name in automatically. This mixin generates all four, reading the name from derived_t::error_type_name.
| derived_t | The error type being defined; must declare a static constexpr std::string_view error_type_name. |
| base_t | The error type to derive from. |
|
inlineprotected |
Forwards an explicit type name, for further derivation.
| ename | Short name of the concrete error type. |
| msg | Human-readable description. |
| exit_code | Process exit code to report. |
|
inlineprotected |
Forwards an explicit type name, for further derivation.
| ename | Short name of the concrete error type. |
| msg | Human-readable description. |
| exit_code | Process exit code to report. |
|
inline |
Constructs the error, naming it from derived_t.
| msg | Human-readable description. |
| exit_code | Process exit code to report. |
|
inline |
Constructs the error, naming it from derived_t.
| msg | Human-readable description. |
| exit_code | Process exit code to report. |