summaryrefslogtreecommitdiff
path: root/include/db/exception.h
blob: 47c99c890b2268b5e9282271e109f974dcaa2803 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/*
 * exception.h
 *
 *  Created on: 28.10.2012
 *      Author: savop
 */

#ifndef EXCEPTION_H_
#define EXCEPTION_H_

#include <exception>
#include <string>

namespace db {

class SQLiteException : public std::exception {
public:
  SQLiteException(std::string msg) throw()
  : message(msg)
  {}
  virtual ~SQLiteException() throw() {}
  virtual const char* what() const throw()
  {
    return message.c_str();
  }
private:
  std::string message;
};

}  // namespace db


#endif /* EXCEPTION_H_ */