diff options
author | Karen Arutyunov <karen@codesynthesis.com> | 2024-02-01 15:48:30 +0300 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2024-02-01 15:48:30 +0300 |
commit | 16577c5292bf23956a5ce81e7e1fe1c3633b3016 (patch) | |
tree | c8f57395975a0f805aaf33893775b6ba18bd2b49 /libodb-oracle/odb/oracle/transaction.ixx | |
parent | 1c7f67f47770a0c8591aeff7c54766c6f5d00cca (diff) | |
parent | 62e234c114d2b6ead93a1d39593c66b648c3d0a6 (diff) |
Merge branch 'libodb-oracle' into multi-package
Diffstat (limited to 'libodb-oracle/odb/oracle/transaction.ixx')
-rw-r--r-- | libodb-oracle/odb/oracle/transaction.ixx | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/libodb-oracle/odb/oracle/transaction.ixx b/libodb-oracle/odb/oracle/transaction.ixx new file mode 100644 index 0000000..d75a399 --- /dev/null +++ b/libodb-oracle/odb/oracle/transaction.ixx @@ -0,0 +1,57 @@ +// file : odb/oracle/transaction.ixx +// 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, bool make_current) + : odb::transaction (impl, make_current) + { + } + + inline transaction:: + transaction () + : odb::transaction () + { + } + + 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 static_cast<connection_type&> (odb::transaction::connection ()); + } + + inline transaction::connection_type& transaction:: + connection (odb::database& db) + { + return static_cast<connection_type&> (odb::transaction::connection (db)); + } + + inline void transaction:: + current (transaction& t) + { + odb::transaction::current (t); + } + } +} |