diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2011-04-18 18:27:15 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2011-04-19 08:39:02 +0200 |
commit | 8f78f966195268149ed1354dacf2b276792f5f7e (patch) | |
tree | a819dbadbdc30b71582f8b049fd1f65543f6dece /odb/relational | |
parent | bef1fce0e10b0b023dcf6e02214730754dc0fe17 (diff) |
Get rid of image type argument in value_traits
Diffstat (limited to 'odb/relational')
-rw-r--r-- | odb/relational/common.cxx | 2 | ||||
-rw-r--r-- | odb/relational/common.hxx | 6 | ||||
-rw-r--r-- | odb/relational/mysql/common.cxx | 7 | ||||
-rw-r--r-- | odb/relational/mysql/source.cxx | 16 | ||||
-rw-r--r-- | odb/relational/sqlite/common.cxx | 7 | ||||
-rw-r--r-- | odb/relational/sqlite/source.cxx | 16 |
6 files changed, 0 insertions, 54 deletions
diff --git a/odb/relational/common.cxx b/odb/relational/common.cxx index a1dbcf8..3e6461b 100644 --- a/odb/relational/common.cxx +++ b/odb/relational/common.cxx @@ -103,13 +103,11 @@ namespace relational } else { - string im_type (image_type (m)); string db_type_id (database_type_id (m)); string type ( string (db.string ()) + "::value_traits< " + m.type ().fq_name (m.belongs ().hint ()) + ", " - + im_type + ", " + db_type_id + " >::query_type"); diff --git a/odb/relational/common.hxx b/odb/relational/common.hxx index be9305f..c7c1c44 100644 --- a/odb/relational/common.hxx +++ b/odb/relational/common.hxx @@ -62,12 +62,6 @@ namespace relational query_columns (semantics::class_&); virtual string - image_type (semantics::data_member&) - { - assert (false); - } - - virtual string database_type_id (semantics::data_member&) { assert (false); diff --git a/odb/relational/mysql/common.cxx b/odb/relational/mysql/common.cxx index e59216e..82acc42 100644 --- a/odb/relational/mysql/common.cxx +++ b/odb/relational/mysql/common.cxx @@ -428,19 +428,12 @@ namespace relational query_columns (base const& x): base (x) {} virtual string - image_type (semantics::data_member& m) - { - return member_image_type_.image_type (m); - } - - virtual string database_type_id (semantics::data_member& m) { return member_database_type_id_.database_type_id (m); } private: - member_image_type member_image_type_; member_database_type_id member_database_type_id_; }; entry<query_columns> query_columns_; diff --git a/odb/relational/mysql/source.cxx b/odb/relational/mysql/source.cxx index cf26082..41e4913 100644 --- a/odb/relational/mysql/source.cxx +++ b/odb/relational/mysql/source.cxx @@ -396,9 +396,6 @@ namespace relational : member_base::base (x), // virtual base base (x), member_base (x), - member_image_type_ (base::type_override_, - base::fq_type_override_, - base::key_prefix_), member_database_type_id_ (base::type_override_, base::fq_type_override_, base::key_prefix_) @@ -437,7 +434,6 @@ namespace relational if (semantics::class_* c = object_pointer (mt)) { type = "obj_traits::id_type"; - image_type = member_image_type_.image_type (mi.m); db_type_id = member_database_type_id_.database_type_id (mi.m); // Handle NULL pointers and extract the id. @@ -482,7 +478,6 @@ namespace relational else { type = mi.fq_type (); - image_type = member_image_type_.image_type (mi.m); db_type_id = member_database_type_id_.database_type_id (mi.m); os << "{" @@ -491,7 +486,6 @@ namespace relational traits = "mysql::value_traits<\n " + type + ",\n " - + image_type + ",\n " + db_type_id + " >"; } @@ -648,10 +642,8 @@ namespace relational string type; string db_type_id; string member; - string image_type; string traits; - member_image_type member_image_type_; member_database_type_id member_database_type_id_; }; entry<init_image_member> init_image_member_; @@ -666,9 +658,6 @@ namespace relational : member_base::base (x), // virtual base base (x), member_base (x), - member_image_type_ (base::type_override_, - base::fq_type_override_, - base::key_prefix_), member_database_type_id_ (base::type_override_, base::fq_type_override_, base::key_prefix_) @@ -704,7 +693,6 @@ namespace relational if (semantics::class_* c = object_pointer (mt)) { type = "obj_traits::id_type"; - image_type = member_image_type_.image_type (mi.m); db_type_id = member_database_type_id_.database_type_id (mi.m); // Handle NULL pointers and extract the id. @@ -731,13 +719,11 @@ namespace relational else { type = mi.fq_type (); - image_type = member_image_type_.image_type (mi.m); db_type_id = member_database_type_id_.database_type_id (mi.m); } traits = "mysql::value_traits<\n " + type + ",\n " - + image_type + ",\n " + db_type_id + " >"; } @@ -886,11 +872,9 @@ namespace relational private: string type; string db_type_id; - string image_type; string traits; string member; - member_image_type member_image_type_; member_database_type_id member_database_type_id_; }; entry<init_value_member> init_value_member_; diff --git a/odb/relational/sqlite/common.cxx b/odb/relational/sqlite/common.cxx index c8169a7..ef880ed 100644 --- a/odb/relational/sqlite/common.cxx +++ b/odb/relational/sqlite/common.cxx @@ -216,19 +216,12 @@ namespace relational query_columns (base const& x): base (x) {} virtual string - image_type (semantics::data_member& m) - { - return member_image_type_.image_type (m); - } - - virtual string database_type_id (semantics::data_member& m) { return member_database_type_id_.database_type_id (m); } private: - member_image_type member_image_type_; member_database_type_id member_database_type_id_; }; entry<query_columns> query_columns_; diff --git a/odb/relational/sqlite/source.cxx b/odb/relational/sqlite/source.cxx index b74f0cf..35a3246 100644 --- a/odb/relational/sqlite/source.cxx +++ b/odb/relational/sqlite/source.cxx @@ -213,9 +213,6 @@ namespace relational : member_base::base (x), // virtual base base (x), member_base (x), - member_image_type_ (base::type_override_, - base::fq_type_override_, - base::key_prefix_), member_database_type_id_ (base::type_override_, base::fq_type_override_, base::key_prefix_) @@ -254,7 +251,6 @@ namespace relational if (semantics::class_* c = object_pointer (mt)) { type = "obj_traits::id_type"; - image_type = member_image_type_.image_type (mi.m); db_type_id = member_database_type_id_.database_type_id (mi.m); // Handle NULL pointers and extract the id. @@ -300,7 +296,6 @@ namespace relational else { type = mi.fq_type (); - image_type = member_image_type_.image_type (mi.m); db_type_id = member_database_type_id_.database_type_id (mi.m); os << "{"; @@ -308,7 +303,6 @@ namespace relational traits = "sqlite::value_traits<\n " + type + ",\n " - + image_type + ",\n " + db_type_id + " >"; } @@ -380,10 +374,8 @@ namespace relational string type; string db_type_id; string member; - string image_type; string traits; - member_image_type member_image_type_; member_database_type_id member_database_type_id_; }; entry<init_image_member> init_image_member_; @@ -398,9 +390,6 @@ namespace relational : member_base::base (x), // virtual base base (x), member_base (x), - member_image_type_ (base::type_override_, - base::fq_type_override_, - base::key_prefix_), member_database_type_id_ (base::type_override_, base::fq_type_override_, base::key_prefix_) @@ -436,7 +425,6 @@ namespace relational if (semantics::class_* c = object_pointer (mt)) { type = "obj_traits::id_type"; - image_type = member_image_type_.image_type (mi.m); db_type_id = member_database_type_id_.database_type_id (mi.m); // Handle NULL pointers and extract the id. @@ -463,13 +451,11 @@ namespace relational else { type = mi.fq_type (); - image_type = member_image_type_.image_type (mi.m); db_type_id = member_database_type_id_.database_type_id (mi.m); } traits = "sqlite::value_traits<\n " + type + ",\n " - + image_type + ",\n " + db_type_id + " >"; } @@ -550,11 +536,9 @@ namespace relational private: string type; string db_type_id; - string image_type; string traits; string member; - member_image_type member_image_type_; member_database_type_id member_database_type_id_; }; entry<init_value_member> init_value_member_; |