added the declaration of the exception used by eoParser::getParam
This commit is contained in:
parent
0808c52bf8
commit
a1aec6a5be
1 changed files with 22 additions and 1 deletions
|
|
@ -55,7 +55,6 @@ private:
|
|||
};
|
||||
|
||||
|
||||
|
||||
/*!
|
||||
An error that signals that a maximum number of evaluations has been reached.
|
||||
|
||||
|
|
@ -80,4 +79,26 @@ private:
|
|||
};
|
||||
|
||||
|
||||
/*!
|
||||
* An error that signals a missing parameter
|
||||
*
|
||||
* Thrown by eoParser::getParam
|
||||
*
|
||||
* @ingroup Parameters
|
||||
*/
|
||||
class eoMissingParamException : public std::exception
|
||||
{
|
||||
public:
|
||||
eoMissingParamException(std::string name) : _name(name){}
|
||||
|
||||
virtual const char* what() const throw()
|
||||
{
|
||||
std::ostringstream ss;
|
||||
ss << "The command parameter " << _name << " has not been declared";
|
||||
return ss.str().c_str();
|
||||
}
|
||||
|
||||
private:
|
||||
std::string _name;
|
||||
};
|
||||
#endif // __eoExceptions_h__
|
||||
|
|
|
|||
Reference in a new issue