aboutsummaryrefslogtreecommitdiff
path: root/common/inheritance/test.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2012-04-23 16:48:03 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2012-04-23 16:48:03 +0200
commit635d11d74cd873e6f53d05b1d9f091ae112402a5 (patch)
tree49a9b835aecba11ff666a7d5c34fd1a248881e78 /common/inheritance/test.hxx
parentadfa9c5ffccdd4e5db8c545d9106c0eb1d7bdcb8 (diff)
Polymorphic inheritance support
Diffstat (limited to 'common/inheritance/test.hxx')
-rw-r--r--common/inheritance/test.hxx12
1 files changed, 11 insertions, 1 deletions
diff --git a/common/inheritance/test.hxx b/common/inheritance/test.hxx
index d679c46..6059337 100644
--- a/common/inheritance/test.hxx
+++ b/common/inheritance/test.hxx
@@ -90,7 +90,7 @@ struct object1: base
#pragma db object
struct object2: base
{
- #pragma db column ("derived_str")
+ #pragma db column("derived_str")
std::string str_;
bool
@@ -145,4 +145,14 @@ struct empty: base
{
};
+// View based on the derived object.
+//
+#pragma db view object(object2)
+struct object2_view
+{
+ unsigned int num; // from abstract_base
+ unsigned long id; // from base
+ std::string str; // from object2, hides one from abstract_base
+};
+
#endif // TEST_HXX