53 lines
1.9 KiB
C
53 lines
1.9 KiB
C
/**
|
||
* @file CSQLite.h
|
||
* @ingroup CSQLite
|
||
* @brief CSQLite is a smart and simple C++ SQLite3 wrapper. This file is only "easy include" for other files.
|
||
*
|
||
* Include this main header file in your project to gain access to all functionality provided by the wrapper.
|
||
*
|
||
CSQLite 是在 SQLiteCpp基础上修改而来,主要区别:
|
||
|
||
1. 减少抛异常。太多抛异常应用层代码就不好写了。
|
||
DataBase类构造时不抛出异常,增加isNull()函数判断数据库打开是否成功。
|
||
Statement bind类函数增加tryBind不抛异常的函数。
|
||
|
||
2. Statement类增加模板函数避免重复代码。
|
||
|
||
3. 针对Qt的修改
|
||
Statement类里面用到的共享指针改成用QSharedPointer实现
|
||
|
||
4. 一些暂时没用上的功能还没加进来,用到再说。
|
||
|
||
*/
|
||
/**
|
||
* @defgroup CSQLite
|
||
* @brief CSQLite is a smart and simple C++ SQLite3 wrapper. This file is only "easy include" for other files.
|
||
*/
|
||
#pragma once
|
||
|
||
// Include useful headers of SQLiteC++
|
||
//#include <SQLiteCpp/Assertion.h>
|
||
#include "CSQLiteException.h"
|
||
#include "CSQLiteDB.h"
|
||
#include "CSQLiteStatement.h"
|
||
#include "CSQLiteColumn.h"
|
||
//#include <SQLiteCpp/Transaction.h>
|
||
|
||
|
||
/**
|
||
* @brief Version numbers for SQLiteC++ are provided in the same way as sqlite3.h
|
||
*
|
||
* The [SQLITECPP_VERSION] C preprocessor macro in the SQLiteC++.h header
|
||
* evaluates to a string literal that is the SQLite version in the
|
||
* format "X.Y.Z" where X is the major version number
|
||
* and Y is the minor version number and Z is the release number.
|
||
*
|
||
* The [SQLITECPP_VERSION_NUMBER] C preprocessor macro resolves to an integer
|
||
* with the value (X*1000000 + Y*1000 + Z) where X, Y, and Z are the same
|
||
* numbers used in [SQLITECPP_VERSION].
|
||
*
|
||
* WARNING: shall always be updated in sync with PROJECT_VERSION in CMakeLists.txt
|
||
*/
|
||
#define CSQLITE_VERSION "1.00.00" // 1.0.0
|
||
#define CSQLITE_VERSION_NUMBER 1000000 // 1.0.0
|