diff options
Diffstat (limited to 'odb/oracle/transaction.ixx')
-rw-r--r-- | odb/oracle/transaction.ixx | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/odb/oracle/transaction.ixx b/odb/oracle/transaction.ixx new file mode 100644 index 0000000..acfa613 --- /dev/null +++ b/odb/oracle/transaction.ixx @@ -0,0 +1,47 @@ +// file : odb/oracle/transaction.ixx +// author : Constantin Michael <constantin@codesynthesis.com> +// copyright : Copyright (c) 2009-2011 Code Synthesis Tools CC +// license : ODB NCUEL; see accompanying LICENSE file + +#include <odb/oracle/database.hxx> +#include <odb/oracle/transaction-impl.hxx> + +namespace odb +{ + namespace oracle + { + inline transaction:: + transaction (transaction_impl* impl) + : odb::transaction (impl) + { + } + + inline transaction_impl& transaction:: + implementation () + { + // We can use static_cast here since we have an instance of + // oracle::transaction. + // + return static_cast<transaction_impl&> ( + odb::transaction::implementation ()); + } + + inline transaction::database_type& transaction:: + database () + { + return static_cast<database_type&> (odb::transaction::database ()); + } + + inline transaction::connection_type& transaction:: + connection () + { + return implementation ().connection (); + } + + inline void transaction:: + current (transaction& t) + { + odb::transaction::current (t); + } + } +} |