#include <Wt/Dbo/backend/Sqlite3>

Public Types | |
| enum | DateTimeStorage { ISO8601AsText, JulianDaysAsReal, UnixTimeAsInteger } |
| Configuration of date time storage. More... | |
Public Member Functions | |
| Sqlite3 (const std::string &db) | |
| Opens a new SQLite3 backend connection. | |
| ~Sqlite3 () | |
| Destructor. | |
| sqlite3 * | connection () |
| Returns the underlying connection. | |
| void | setDateTimeStorage (SqlDateTimeType type, DateTimeStorage format) |
| Configures how to store date or date time. | |
| DateTimeStorage | dateTimeStorage (SqlDateTimeType type) const |
| Returns the date time storage. | |
| virtual void | startTransaction () |
| Starts a transaction. | |
| virtual void | commitTransaction () |
| Commits a transaction. | |
| virtual void | rollbackTransaction () |
| Rolls back a transaction. | |
| virtual SqlStatement * | prepareStatement (const std::string &sql) |
| Prepares a statement. | |
Methods that return dialect information | |
| virtual std::string | autoincrementSql () const |
| Returns the 'autoincrement' SQL type modifier. | |
| virtual std::string | autoincrementType () const |
| Returns the 'autoincrement' SQL type. | |
| virtual std::string | autoincrementInsertSuffix () const |
| Returns the suffix for an 'autoincrement' insert statement. | |
| virtual const char * | dateTimeType (SqlDateTimeType type) const |
| Returns the date/time type. | |
| virtual const char * | blobType () const |
| Returns the blob type. | |
This class provides the backend implementation for SQLite3 databases.
Configuration of date time storage.
SQlite3 does not provide real type support for date time. Instead, it offers 3 choices for storing a date time, each of these compatible with the use of the built-in arithmetic functions.
| Wt::Dbo::backend::Sqlite3::Sqlite3 | ( | const std::string & | db | ) |
Opens a new SQLite3 backend connection.
The db may be any of the values supported by sqlite3_open().
| Wt::Dbo::backend::Sqlite3::~Sqlite3 | ( | ) |
Destructor.
Closes the connection.
| void Wt::Dbo::backend::Sqlite3::setDateTimeStorage | ( | SqlDateTimeType | type, | |
| DateTimeStorage | format | |||
| ) |
Configures how to store date or date time.
The default format is ISO8601AsText.
| void Wt::Dbo::backend::Sqlite3::startTransaction | ( | ) | [virtual] |
| void Wt::Dbo::backend::Sqlite3::commitTransaction | ( | ) | [virtual] |
| void Wt::Dbo::backend::Sqlite3::rollbackTransaction | ( | ) | [virtual] |
Rolls back a transaction.
This function rolls back a transaction.
Implements Wt::Dbo::SqlConnection.
| SqlStatement * Wt::Dbo::backend::Sqlite3::prepareStatement | ( | const std::string & | sql | ) | [virtual] |
| std::string Wt::Dbo::backend::Sqlite3::autoincrementSql | ( | ) | const [virtual] |
Returns the 'autoincrement' SQL type modifier.
This is used by Session::createTables() to create the id column.
Implements Wt::Dbo::SqlConnection.
| std::string Wt::Dbo::backend::Sqlite3::autoincrementType | ( | ) | const [virtual] |
Returns the 'autoincrement' SQL type.
This is used by Session::createTables() to create the id column.
Implements Wt::Dbo::SqlConnection.
| std::string Wt::Dbo::backend::Sqlite3::autoincrementInsertSuffix | ( | ) | const [virtual] |
Returns the suffix for an 'autoincrement' insert statement.
This is appended to the insert statement, since some back-ends need to be indicated that they should return the autoincrement id.
Implements Wt::Dbo::SqlConnection.
| const char * Wt::Dbo::backend::Sqlite3::dateTimeType | ( | SqlDateTimeType | type | ) | const [virtual] |
| const char * Wt::Dbo::backend::Sqlite3::blobType | ( | ) | const [virtual] |
1.5.6