aboutsummaryrefslogtreecommitdiff
path: root/odb/sqlite/simple-object-statements.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'odb/sqlite/simple-object-statements.hxx')
-rw-r--r--odb/sqlite/simple-object-statements.hxx21
1 files changed, 14 insertions, 7 deletions
diff --git a/odb/sqlite/simple-object-statements.hxx b/odb/sqlite/simple-object-statements.hxx
index a1e7678..f438d90 100644
--- a/odb/sqlite/simple-object-statements.hxx
+++ b/odb/sqlite/simple-object-statements.hxx
@@ -244,8 +244,10 @@ namespace odb
// Delayed loading.
//
- typedef void (*loader_function) (
- odb::database&, const id_type&, object_type&);
+ typedef void (*loader_function) (odb::database&,
+ const id_type&,
+ object_type&,
+ const schema_version_migration*);
void
delay_load (const id_type& id,
@@ -257,12 +259,12 @@ namespace odb
}
void
- load_delayed ()
+ load_delayed (const schema_version_migration* svm)
{
assert (locked ());
if (!delayed_.empty ())
- load_delayed_ ();
+ load_delayed_<object_statements> (svm);
}
void
@@ -351,6 +353,7 @@ namespace odb
new (details::shared) insert_statement_type (
conn_,
object_traits::persist_statement,
+ object_traits::versioned, // Process if versioned.
insert_image_binding_));
}
@@ -366,6 +369,8 @@ namespace odb
new (details::shared) select_statement_type (
conn_,
object_traits::find_statement,
+ object_traits::versioned, // Process if versioned.
+ false, // Don't optimize.
id_image_binding_,
select_image_binding_));
}
@@ -382,6 +387,7 @@ namespace odb
new (details::shared) update_statement_type (
conn_,
object_traits::update_statement,
+ object_traits::versioned, // Process if versioned.
update_image_binding_));
}
@@ -458,14 +464,15 @@ namespace odb
object_statements (const object_statements&);
object_statements& operator= (const object_statements&);
- private:
+ protected:
+ template <typename STS>
void
- load_delayed_ ();
+ load_delayed_ (const schema_version_migration*);
void
clear_delayed_ ();
- private:
+ protected:
template <typename T1>
friend class polymorphic_derived_object_statements;