diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2010-11-17 18:05:06 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2010-11-17 18:05:06 +0200 |
commit | 2fe7a723c0b98d23531a76d9c1a451e3a57bf0c5 (patch) | |
tree | 8bd0323a9114a405902b3dfc116f97307278ae2b /odb/mysql/common.hxx | |
parent | 302b804ec633889f26dc54d937d9becc09246152 (diff) |
Add support for unidirectional object relationships
New test: common/relationship.
Diffstat (limited to 'odb/mysql/common.hxx')
-rw-r--r-- | odb/mysql/common.hxx | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/odb/mysql/common.hxx b/odb/mysql/common.hxx index 31c6962..fb1f2a3 100644 --- a/odb/mysql/common.hxx +++ b/odb/mysql/common.hxx @@ -46,7 +46,13 @@ namespace mysql string fq_type () const { - return fq_type_.empty () ? t.fq_name (m.belongs ().hint ()) : fq_type_; + // Use the original type from 'm' instead of 't' since the hint + // may be invalid for a different type. Plus, if a type is + // overriden, then the fq_type must be as well. + // + return fq_type_.empty () + ? m.type ().fq_name (m.belongs ().hint ()) + : fq_type_; } string const& fq_type_; @@ -81,6 +87,15 @@ namespace mysql } virtual void + traverse_object_pointer (member_info& mi) + { + traverse_simple (mi); + } + + virtual void + traverse_simple (member_info&); + + virtual void traverse_integer (member_info&) { } |