summaryrefslogtreecommitdiff
path: root/odb/header.cxx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2011-08-04 13:29:43 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2011-08-04 13:29:43 +0200
commit14392d7ca625facaf509b354f19ece627b81a4b0 (patch)
treee422c02227501f2e7e29a20f69dcac4b8d82ba40 /odb/header.cxx
parentc7a98034ccc3425090dddade05fd09d54d1f940f (diff)
Add support for value wrappers
Wrapper is a class that wraps another type. Examples of wrappers are various smart pointers, holders, etc. A wrapper can be transparent or it can handle the NULL semantics. The new odb::nullable class template is a NULL wrapper that helps to add the NULL semantics to a value type. New test: common/wrapper.
Diffstat (limited to 'odb/header.cxx')
-rw-r--r--odb/header.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/odb/header.cxx b/odb/header.cxx
index 62902f6..a17b111 100644
--- a/odb/header.cxx
+++ b/odb/header.cxx
@@ -89,6 +89,7 @@ namespace header
os << "#include <odb/core.hxx>" << endl
<< "#include <odb/traits.hxx>" << endl
<< "#include <odb/callback.hxx>" << endl
+ << "#include <odb/wrapper-traits.hxx>" << endl
<< "#include <odb/pointer-traits.hxx>" << endl;
// In case of a boost TR1 implementation, we cannot distinguish
@@ -99,12 +100,14 @@ namespace header
if (ctx.unit.count ("tr1-pointer-used") &&
ctx.unit.get<bool> ("tr1-pointer-used"))
{
- os << "#include <odb/tr1/pointer-traits.hxx>" << endl;
+ os << "#include <odb/tr1/wrapper-traits.hxx>" << endl
+ << "#include <odb/tr1/pointer-traits.hxx>" << endl;
}
else if (ctx.unit.count ("boost-pointer-used") &&
ctx.unit.get<bool> ("boost-pointer-used"))
{
os << "#ifdef BOOST_TR1_MEMORY_HPP_INCLUDED" << endl
+ << "# include <odb/tr1/wrapper-traits.hxx>" << endl
<< "# include <odb/tr1/pointer-traits.hxx>" << endl
<< "#endif" << endl;
}