diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2011-03-24 12:35:08 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2011-03-24 12:35:08 +0200 |
commit | 8f59ca1a8d7093655f8f7d61f101abc6df3839d5 (patch) | |
tree | 2555c001df7b81560bdc3c579f8c84260c168203 /odb/relational/context.hxx | |
parent | 9cb4ce54829fb2f091e8690b591440b4369a1387 (diff) |
Generalization work for MySQL and SQLite support
Diffstat (limited to 'odb/relational/context.hxx')
-rw-r--r-- | odb/relational/context.hxx | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/odb/relational/context.hxx b/odb/relational/context.hxx index c99b400..08f8b81 100644 --- a/odb/relational/context.hxx +++ b/odb/relational/context.hxx @@ -33,6 +33,34 @@ namespace relational string quote_id (string const&) const; + // Quoted column and table names. + // + string + column_qname (semantics::data_member& m) const + { + return quote_id (column_name (m)); + } + + string + column_qname (semantics::data_member& m, + string const& key_prefix, + string const& default_name) const + { + return quote_id (column_name (m, key_prefix, default_name)); + } + + string + table_qname (semantics::class_& c) const + { + return quote_id (table_name (c)); + } + + string + table_qname (semantics::data_member& m, table_prefix const& p) const + { + return quote_id (table_name (m, p)); + } + protected: // The default implementation returns false. // @@ -76,8 +104,15 @@ namespace relational struct data: root_context::data { data (std::ostream& os): root_context::data (os) {} + + string bind_vector_; + string truncated_vector_; }; data* data_; + + public: + string const& bind_vector; + string const& truncated_vector; }; } |