aboutsummaryrefslogtreecommitdiff
path: root/odb/sqlite/exceptions.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'odb/sqlite/exceptions.cxx')
-rw-r--r--odb/sqlite/exceptions.cxx56
1 files changed, 56 insertions, 0 deletions
diff --git a/odb/sqlite/exceptions.cxx b/odb/sqlite/exceptions.cxx
new file mode 100644
index 0000000..6801665
--- /dev/null
+++ b/odb/sqlite/exceptions.cxx
@@ -0,0 +1,56 @@
+// file : odb/sqlite/exceptions.cxx
+// author : Boris Kolpackov <boris@codesynthesis.com>
+// copyright : Copyright (c) 2005-2011 Code Synthesis Tools CC
+// license : GNU GPL v2; see accompanying LICENSE file
+
+#include <odb/sqlite/exceptions.hxx>
+
+using namespace std;
+
+namespace odb
+{
+ namespace sqlite
+ {
+ //
+ // database_exception
+ //
+
+ database_exception::
+ ~database_exception () throw ()
+ {
+ }
+
+ database_exception::
+ database_exception (int e, int ee, const string& m)
+ : error_ (e), extended_error_ (ee), message_ (m)
+ {
+ }
+
+ const char* database_exception::
+ what () const throw ()
+ {
+ return message_.c_str ();
+ }
+
+ //
+ // cli_exception
+ //
+
+ cli_exception::
+ cli_exception (const std::string& what)
+ : what_ (what)
+ {
+ }
+
+ cli_exception::
+ ~cli_exception () throw ()
+ {
+ }
+
+ const char* cli_exception::
+ what () const throw ()
+ {
+ return what_.c_str ();
+ }
+ }
+}