#include <exception>
#include <string>
-#include "backtrace.h"
+#include "../debug/backtrace.h"
namespace Msp {
~Exception() throw() { }
const char *what() const throw() { return w.c_str(); }
- const Backtrace &get_backtrace() const throw() { return bt; }
+ const Debug::Backtrace &get_backtrace() const throw() { return bt; }
private:
std::string w;
- Backtrace bt;
+ Debug::Backtrace bt;
};
InvalidParameterValue(const std::string &w_): Exception(w_) { }
};
+/**
+Thrown when a lookup from a map fails.
+*/
+class KeyError: public Exception
+{
+public:
+ KeyError(const std::string &w_): Exception(w_) { }
+};
+
/**
Thrown when the current object state doesn't allow the requested action.
*/