Common C++ classes and routines used by my applications such as argument parser, IO and conversion utilities
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

44 lines
752 B

#include "./failure.h"
namespace ApplicationUtilities {
/*!
* \class ApplicationUtilities::Failure
* \brief The Failure class is thrown by an ArgumentParser when a parsing error occurs.
*
* \sa ApplicationUtilities::ArgumentParser
*/
/*!
* Constructs a new Failure.
*/
Failure::Failure() :
m_what("unspecified parsing exception")
{}
/*!
* Constructs a new Failure. \a what is a std::string
* describing the cause of the Failure.
*/
Failure::Failure(const std::string &what) :
m_what(what)
{}
/*!
* Destroys the Failure.
*/
Failure::~Failure() USE_NOTHROW
{}
/*!
* Returns a C-style character string describing the cause
* of the Failure.
*/
const char *Failure::what() const USE_NOTHROW
{
return m_what.c_str();
}
}