You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, the QueryBuilder type requires a database connection (impl DatabaseConnection) to be provided during its construction. To improve usability and flexibility, we should refactor QueryBuilder so that the database connection is supplied at the time of query execution, rather than during initialization.
Tasks:
Modify the QueryBuilder struct to remove the database connection from its fields.
Update the query(...) method to accept a reference to a database connection (&impl DatabaseConnection) as a parameter.
Ensure that the QueryBuilder remains trivially copyable and that instances can be reused without consuming the struct.
Adjust existing code and macros that utilize QueryBuilder to align with this new design.
Write or update unit tests to confirm that the refactored QueryBuilder behaves as expected with the deferred database connection.
Expected Outcome:
A refactored QueryBuilder that defers the database connection requirement to the query execution phase, resulting in a more flexible and reusable API.
The text was updated successfully, but these errors were encountered:
Description:
Currently, the QueryBuilder type requires a database connection (impl DatabaseConnection) to be provided during its construction. To improve usability and flexibility, we should refactor QueryBuilder so that the database connection is supplied at the time of query execution, rather than during initialization.
Tasks:
Expected Outcome:
A refactored QueryBuilder that defers the database connection requirement to the query execution phase, resulting in a more flexible and reusable API.
The text was updated successfully, but these errors were encountered: