aboutsummaryrefslogtreecommitdiff
path: root/odb/connection.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'odb/connection.hxx')
-rw-r--r--odb/connection.hxx18
1 files changed, 18 insertions, 0 deletions
diff --git a/odb/connection.hxx b/odb/connection.hxx
index 9f42f33..f274b39 100644
--- a/odb/connection.hxx
+++ b/odb/connection.hxx
@@ -11,6 +11,8 @@
#include <cstddef> // std::size_t
#include <odb/forward.hxx>
+#include <odb/query.hxx>
+#include <odb/prepared-query.hxx>
#include <odb/details/export.hxx>
#include <odb/details/shared-ptr.hxx>
@@ -50,6 +52,21 @@ namespace odb
virtual unsigned long long
execute (const char* statement, std::size_t length) = 0;
+ // Query preparation.
+ //
+ public:
+ template <typename T>
+ prepared_query<T>
+ prepare_query (const char* name, const char* q);
+
+ template <typename T>
+ prepared_query<T>
+ prepare_query (const char* name, const std::string& q);
+
+ template <typename T>
+ prepared_query<T>
+ prepare_query (const char* name, const query<T>& q);
+
// SQL statement tracing.
//
public:
@@ -96,6 +113,7 @@ namespace odb
}
#include <odb/connection.ixx>
+#include <odb/connection.txx>
#include <odb/post.hxx>