Re: [sqlite] Formal review of Boost.SQLite begins

May I ask why? I am not hiding the implementation (i.e. sqlite3) on purpose, so that users can just use the sqlite3 API or another library if they need.
Hiding types such as `sqlite3` with a `void*` in that case would be beneficial, as you would make the user's life easier because they would treat the `handle_type` as a handle, not a specific type accessible by the user. So as the implementer you would be able to extend the library without breaking changes.
Not being able to do that has caused me much frustration in other libraries before.
May I ask about what specific libraries you have in mind?
Which usage do you have in mind? As a query builder?
Indeed, The query_builder object takes a `connection` object in the constructor. And that can be swapped with another `connection` when needed. ```cpp class query_builder { public: /// operator<< query_builder& operator<<(const cstring_ref& sql_query); /// operator>> query_builder& operator>>(resultset& res_out); }; /// example void cache_manager::read_local_cache() { resultset res{}; cstring_ref in = "SELECT * FROM cache WHERE key = \"?\""; this->builder_ << in; this->builder_ >> res; } ```
Thank you for your review!
It is my pleasure! Amlal
participants (1)
-
amlalelmahrouss@icloud.com