![]() |
AnCH Framework
0.1
Another C++ Hack Framework
|
SQLite3 connection. More...
#include <sqlite3Connection.hpp>
Public Member Functions | |
| SQLite3Connection (const std::string &database) throw (SqlException) | |
| SQLite3Connection (const SqlConnectionConfiguration &config) throw (SqlException) | |
| SQLite3Connection (const SQLite3Connection &)=delete | |
| ~SQLite3Connection () | |
Public Member Functions inherited from anch::sql::Connection | |
| Connection () throw (SqlException) | |
| Connection (const Connection &)=delete | |
| virtual | ~Connection () |
| void | commit () throw (SqlException) |
| void | rollback () throw (SqlException) |
| void | setAutoCommit (bool autoCommit) throw (SqlException) |
| ResultSet * | query (const std::string &query) throw (SqlException) |
| void | queryMapRow (const std::string &sqlQuery, std::function< void(ResultSet &)> rowMapper) throw (SqlException) |
| void | queryExtract (const std::string &sqlQuery, std::function< void(ResultSet &)> resExtractor) throw (SqlException) |
| uint64_t | update (const std::string &query) throw (SqlException) |
| bool | isAutoCommit () const |
| bool | isValid () const |
Protected Member Functions | |
| virtual ResultSet * | executeQuery (const std::string &query) override throw (SqlException) |
| virtual uint64_t | executeUpdate (const std::string &query) override throw (SqlException) |
| virtual void | sendCommit () override throw (SqlException) |
| virtual void | sendRollback () override throw (SqlException) |
| virtual void | toggleAutoCommit (bool autoCommit) override throw (SqlException) |
Protected Member Functions inherited from anch::sql::Connection | |
| void | setValid (bool valid) |
Additional Inherited Members | |
Protected Attributes inherited from anch::sql::Connection | |
| bool | _autoCommit |
| bool | _valid |
SQLite3 connection.
SQL connection implementation through SQLite3 native library
| SQLite3Connection::SQLite3Connection | ( | const std::string & | database | ) | |
| throw | ( | SqlException | |||
| ) | |||||
SQLite3Connection constructor
| database | the database path |
| SqlException | fail to create connection |
| SQLite3Connection::SQLite3Connection | ( | const SqlConnectionConfiguration & | config | ) | |
| throw | ( | SqlException | |||
| ) | |||||
SQLite3Connection constructor
| config | the SQLite3 configuration |
| SqlException | fail to create connection |
|
delete |
Prohibit SQLite3Connection copy constructor
| SQLite3Connection::~SQLite3Connection | ( | ) |
SQLite3Connection destructor
|
overrideprotectedvirtual | ||||||||||||||
Execute SQL select query
| query | the SQL query to execute |
| SqlException | any error |
Implements anch::sql::Connection.
|
overrideprotectedvirtual | ||||||||||||||
Execute SQL update query
| query | the SQL query to execute |
| SqlException | any error |
Implements anch::sql::Connection.
|
overrideprotectedvirtual | |||||||||||||
Send commit to database server
| SqlException | fail to commit transaction |
Implements anch::sql::Connection.
|
overrideprotectedvirtual | |||||||||||||
Send rollback to database server
| SqlException | fail to rollback transaction |
Implements anch::sql::Connection.
|
overrideprotectedvirtual | ||||||||||||||
Send auto commit status modification to server
| autoCommit | the status to send |
| SqlException | any error |
Implements anch::sql::Connection.
1.8.11