summaryrefslogtreecommitdiff
path: root/odb/context.hxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2012-01-08 17:27:40 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2012-01-08 17:27:40 +0200
commit4fd6bca4e75870958ea61b94e0a1e60e78cd91bc (patch)
tree2119cae72f45e1ceff1982d8364b4b678ac4ee69 /odb/context.hxx
parent7cd11b5f604c7d786261568aa31cd2ae3638f61e (diff)
Add support for defining composite value type as class template instantiations
Diffstat (limited to 'odb/context.hxx')
-rw-r--r--odb/context.hxx25
1 files changed, 18 insertions, 7 deletions
diff --git a/odb/context.hxx b/odb/context.hxx
index 3be05a9..919e880 100644
--- a/odb/context.hxx
+++ b/odb/context.hxx
@@ -132,13 +132,7 @@ struct view_object
// Return an alias or unqualified object name.
//
std::string
- name () const
- {
- if (!alias.empty ())
- return alias;
-
- return kind == object ? obj->name () : orig_name;
- }
+ name () const;
enum kind_type { object, table };
@@ -430,6 +424,23 @@ public:
static class_kind_type
class_kind (semantics::class_&);
+ // Return class names. For ordinary classes, this will be the class
+ // name itself. For class template instantiations this will be the
+ // typedef name used in the pragma.
+ //
+ static string
+ class_name (semantics::class_&);
+
+ static string
+ class_fq_name (semantics::class_&);
+
+ // Return the class file. For ordinary classes, this will be the file
+ // where the class is defined. For class template instantiations this
+ // will be the file containing the pragma.
+ //
+ static semantics::path
+ class_file (semantics::class_&);
+
// Database names and types.
//
public: