|
cli11
|
An option received the wrong number of values. More...
Public Member Functions | |
| argument_mismatch_t (std::string msg) | |
| Constructs the error with the default exit code. | |
| argument_mismatch_t (const std::string &name, int expected, std::size_t received) | |
| An option received a count other than the one it expects. | |
| Public Member Functions inherited from cli::detail::error_mixin_t< argument_mismatch_t, parse_error_t > | |
| 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. | |
| Public Member Functions inherited from cli::detail::error_mixin_t< parse_error_t, error_t > | |
| 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. | |
| Public Member Functions inherited from cli::error_t | |
| auto | get_exit_code () const -> int |
| Returns the process exit code associated with this error. | |
| auto | get_name () const -> std::string |
| Returns the short name of this error type. | |
| error_t (std::string name, std::string msg, int exit_code=static_cast< int >(exit_codes_t::base_class)) | |
| Constructs an error with an explicit numeric exit code. | |
| error_t (std::string name, std::string msg, exit_codes_t exit_code) | |
| Constructs an error with an exit code drawn from exit_codes_t. | |
Static Public Member Functions | |
| static auto | at_least (const std::string &name, int num, std::size_t received) -> argument_mismatch_t |
| Fewer values arrived than the minimum. | |
| static auto | at_most (const std::string &name, int num, std::size_t received) -> argument_mismatch_t |
| More values arrived than the maximum. | |
| static auto | typed_at_least (const std::string &name, int num, const std::string &type) -> argument_mismatch_t |
| Too few values arrived to fill one element of a typed option. | |
| static auto | flag_override (const std::string &name) -> argument_mismatch_t |
| A flag override was supplied where none is allowed. | |
| static auto | partial_type (const std::string &name, int num, const std::string &type) -> argument_mismatch_t |
| A compound element was only partially supplied. | |
Static Public Attributes | |
| static constexpr std::string_view | error_type_name = "argument_mismatch" |
| Short name reported by error_t::get_name. | |
| Static Public Attributes inherited from cli::parse_error_t | |
| static constexpr std::string_view | error_type_name = "parse_error" |
| Short name reported by error_t::get_name. | |
Additional Inherited Members | |
| Protected Member Functions inherited from cli::detail::error_mixin_t< argument_mismatch_t, parse_error_t > | |
| 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. | |
| Protected Member Functions inherited from cli::detail::error_mixin_t< parse_error_t, error_t > | |
| 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. | |
An option received the wrong number of values.
|
inlineexplicit |
Constructs the error with the default exit code.
| msg | Human-readable description. |
|
inline |
An option received a count other than the one it expects.
| name | The offending option. |
| expected | Expected count; negative means "at least this many". |
| received | How many values arrived. |
|
inlinestaticnodiscard |
Fewer values arrived than the minimum.
| name | The offending option. |
| num | The minimum required. |
| received | How many values arrived. |
|
inlinestaticnodiscard |
More values arrived than the maximum.
| name | The offending option. |
| num | The maximum permitted. |
| received | How many values arrived. |
|
inlinestaticnodiscard |
A flag override was supplied where none is allowed.
| name | The offending flag. |
|
inlinestaticnodiscard |
A compound element was only partially supplied.
| name | The offending option. |
| num | Values required per element. |
| type | Name of the element type. |
|
inlinestaticnodiscard |
Too few values arrived to fill one element of a typed option.
| name | The offending option. |
| num | The number required. |
| type | Name of the element type. |