From dac72baef46897b80fc98632cef182fb266a5d60 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Mon, 21 Mar 2011 17:24:35 +0200 Subject: Add base SQLite database classes --- odb/sqlite/transaction-impl.hxx | 55 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 odb/sqlite/transaction-impl.hxx (limited to 'odb/sqlite/transaction-impl.hxx') diff --git a/odb/sqlite/transaction-impl.hxx b/odb/sqlite/transaction-impl.hxx new file mode 100644 index 0000000..cc38039 --- /dev/null +++ b/odb/sqlite/transaction-impl.hxx @@ -0,0 +1,55 @@ +// file : odb/sqlite/transaction-impl.hxx +// author : Boris Kolpackov +// copyright : Copyright (c) 2009-2011 Code Synthesis Tools CC +// license : GNU GPL v2; see accompanying LICENSE file + +#ifndef ODB_SQLITE_TRANSACTION_IMPL_HXX +#define ODB_SQLITE_TRANSACTION_IMPL_HXX + +#include + +#include +#include + +#include +#include +#include + +namespace odb +{ + namespace sqlite + { + class LIBODB_SQLITE_EXPORT transaction_impl: public odb::transaction_impl + { + protected: + friend class database; + friend class transaction; + + typedef sqlite::database database_type; + typedef sqlite::connection connection_type; + + transaction_impl (database_type&); + + virtual + ~transaction_impl (); + + virtual void + commit (); + + virtual void + rollback (); + + connection_type& + connection (); + + private: + details::shared_ptr connection_; + }; + } +} + +#include + +#include + +#endif // ODB_SQLITE_TRANSACTION_IMPL_HXX -- cgit v1.1