Exception class raised when an argument is used an incorrect amount of times. More...
#include <Exceptions.hpp>
Public Member Functions | |
argument_count_mismatch (const Argument &arg, unsigned int count, unsigned int expected) | |
Creates the exception for the given argument, with the number of occurrences and the expected number of occurrences. More... | |
![]() | |
argument_error (const Argument &arg) | |
Creates the exception for the given argument, without a specified reason. More... | |
argument_error (const Argument &arg, const std::string &reason) | |
Creates the exception for the given argument, with a specified reason. More... | |
const Argument & | arg () const |
Returns the argument triggering the error. More... | |
![]() | |
exception (std::string what) | |
Creates the exception with the given message. More... | |
exception () | |
Creates the exception with no message. | |
const char * | what () const noexceptoverride |
See std::exception::what(). | |
Additional Inherited Members | |
![]() | |
std::unique_ptr< Argument > | m_arg |
Copy of the argument involved in the error. | |
![]() | |
std::string | m_what |
Description of the exception. More... | |
Exception class raised when an argument is used an incorrect amount of times.
|
inline |
Creates the exception for the given argument, with the number of occurrences and the expected number of occurrences.
If the expected value is higher, it is assumed to be a minimum, otherwise a maximum.
arg | The argument with an error |
count | The number of times the argument occurred |
expected | The number of times the argument was expected to occur |