aboutsummaryrefslogtreecommitdiff
path: root/odb/sqlite/query.ixx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2011-03-25 13:04:55 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2011-03-25 13:04:55 +0200
commitb5d76bf8ab11e73b260cbc4343c1f947c0da2699 (patch)
treee9221606eb5c4478e4f11ff14c032b8ba81c0c4a /odb/sqlite/query.ixx
parent5d084dcd0f24237486e18f024fbbb14c13b8bffe (diff)
Query support
Diffstat (limited to 'odb/sqlite/query.ixx')
-rw-r--r--odb/sqlite/query.ixx40
1 files changed, 40 insertions, 0 deletions
diff --git a/odb/sqlite/query.ixx b/odb/sqlite/query.ixx
new file mode 100644
index 0000000..f51da5a
--- /dev/null
+++ b/odb/sqlite/query.ixx
@@ -0,0 +1,40 @@
+// file : odb/sqlite/query.ixx
+// author : Boris Kolpackov <boris@codesynthesis.com>
+// copyright : Copyright (c) 2009-2011 Code Synthesis Tools CC
+// license : GNU GPL v2; see accompanying LICENSE file
+
+namespace odb
+{
+ namespace sqlite
+ {
+ inline binding& query::
+ parameters_binding () const
+ {
+ return parameters_->binding ();
+ }
+
+ inline details::shared_ptr<query_params> query::
+ parameters () const
+ {
+ return parameters_;
+ }
+
+ template <typename T, database_type_id ID>
+ inline void query::
+ append (val_bind<T> v)
+ {
+ add (
+ details::shared_ptr<query_param> (
+ new (details::shared) query_param_impl<T, ID> (v)));
+ }
+
+ template <typename T, database_type_id ID>
+ inline void query::
+ append (ref_bind<T> r)
+ {
+ add (
+ details::shared_ptr<query_param> (
+ new (details::shared) query_param_impl<T, ID> (r)));
+ }
+ }
+}