|
ocpp 0.24.1
A C++ implementation of the Open Charge Point Protocol
|
Public Member Functions | |
| DatabaseConnection (const fs::path &database_file_path) noexcept | |
| bool | open_connection () override |
| Opens the database connection. Returns true if succeeded. More... | |
| bool | close_connection () override |
| Closes the database connection. Returns true if succeeded. More... | |
| std::unique_ptr< DatabaseTransactionInterface > | begin_transaction () override |
| Start a transaction on the database. Returns an object holding the transaction. More... | |
| bool | execute_statement (const std::string &statement) override |
Immediately executes statement. Returns true if succeeded. More... | |
| std::unique_ptr< SQLiteStatementInterface > | new_statement (const std::string &sql) override |
| Returns a new SQLiteStatementInterface to be used to perform more advanced sql statements. More... | |
| const char * | get_error_message () override |
| Returns the latest error message from sqlite3. More... | |
| bool | clear_table (const std::string &table) override |
Clears the table with name table. Returns true if succeeded. More... | |
| int64_t | get_last_inserted_rowid () override |
| Gets the last inserted rowid. More... | |
| uint32_t | get_user_version () override |
| Helper function to get the user version of the database. More... | |
| void | set_user_version (uint32_t version) override |
Helper function to set the user version of the database to version. More... | |
| virtual bool | open_connection ()=0 |
| Opens the database connection. Returns true if succeeded. More... | |
| virtual bool | close_connection ()=0 |
| Closes the database connection. Returns true if succeeded. More... | |
| virtual std::unique_ptr< DatabaseTransactionInterface > | begin_transaction ()=0 |
| Start a transaction on the database. Returns an object holding the transaction. More... | |
| virtual bool | execute_statement (const std::string &statement)=0 |
Immediately executes statement. Returns true if succeeded. More... | |
| virtual std::unique_ptr< SQLiteStatementInterface > | new_statement (const std::string &sql)=0 |
| Returns a new SQLiteStatementInterface to be used to perform more advanced sql statements. More... | |
| virtual const char * | get_error_message ()=0 |
| Returns the latest error message from sqlite3. More... | |
| virtual bool | clear_table (const std::string &table)=0 |
Clears the table with name table. Returns true if succeeded. More... | |
| virtual int64_t | get_last_inserted_rowid ()=0 |
| Gets the last inserted rowid. More... | |
| virtual void | set_user_version (uint32_t version)=0 |
Helper function to set the user version of the database to version. More... | |
| virtual uint32_t | get_user_version ()=0 |
| Helper function to get the user version of the database. More... | |
|
overridevirtual |
Start a transaction on the database. Returns an object holding the transaction.
Implements ocpp::common::DatabaseConnectionInterface.
|
overridevirtual |
Clears the table with name table. Returns true if succeeded.
Implements ocpp::common::DatabaseConnectionInterface.
|
overridevirtual |
Closes the database connection. Returns true if succeeded.
Implements ocpp::common::DatabaseConnectionInterface.
|
overridevirtual |
Immediately executes statement. Returns true if succeeded.
Implements ocpp::common::DatabaseConnectionInterface.
|
overridevirtual |
Returns the latest error message from sqlite3.
Implements ocpp::common::DatabaseConnectionInterface.
|
overridevirtual |
Gets the last inserted rowid.
Implements ocpp::common::DatabaseConnectionInterface.
|
overridevirtual |
Helper function to get the user version of the database.
Implements ocpp::common::DatabaseConnectionInterface.
|
overridevirtual |
Returns a new SQLiteStatementInterface to be used to perform more advanced sql statements.
Implements ocpp::common::DatabaseConnectionInterface.
|
overridevirtual |
Opens the database connection. Returns true if succeeded.
Implements ocpp::common::DatabaseConnectionInterface.
|
overridevirtual |
Helper function to set the user version of the database to version.
Implements ocpp::common::DatabaseConnectionInterface.