summaryrefslogtreecommitdiff
path: root/vendor/bandit/bandit/assertion_frameworks/snowhouse/snowhouse/assertionexception.h
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/bandit/bandit/assertion_frameworks/snowhouse/snowhouse/assertionexception.h')
-rw-r--r--vendor/bandit/bandit/assertion_frameworks/snowhouse/snowhouse/assertionexception.h48
1 files changed, 48 insertions, 0 deletions
diff --git a/vendor/bandit/bandit/assertion_frameworks/snowhouse/snowhouse/assertionexception.h b/vendor/bandit/bandit/assertion_frameworks/snowhouse/snowhouse/assertionexception.h
new file mode 100644
index 00000000..77890a7e
--- /dev/null
+++ b/vendor/bandit/bandit/assertion_frameworks/snowhouse/snowhouse/assertionexception.h
@@ -0,0 +1,48 @@
+
+// Copyright Joakim Karlsson & Kim Gräsman 2010-2012.
+// Distributed under the Boost Software License, Version 1.0.
+// (See accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt)
+
+#ifndef IGLOO_ASSERTIONEXCEPTION_H
+#define IGLOO_ASSERTIONEXCEPTION_H
+
+namespace snowhouse {
+ class AssertionException : public std::exception
+ {
+ public:
+ AssertionException(const std::string& message)
+ : m_message(message), m_fileName(""), m_line(0)
+ {}
+
+ AssertionException(const std::string& message, const std::string& fileName, unsigned int line)
+ : m_message(message), m_fileName(fileName), m_line(line)
+ {}
+
+ virtual ~AssertionException() throw()
+ {
+ }
+
+ std::string GetMessage() const
+ {
+ return m_message;
+ }
+
+ std::string GetFilename() const
+ {
+ return m_fileName;
+ }
+
+ unsigned int GetLineNumber() const
+ {
+ return m_line;
+ }
+
+ private:
+ std::string m_message;
+ std::string m_fileName;
+ unsigned int m_line;
+ };
+}
+
+#endif // IGLOO_ASSERTIONEXCEPTION_H