subtransaction.hxx

Go to the documentation of this file.
00001 /*-------------------------------------------------------------------------
00002  *
00003  *   FILE
00004  *      pqxx/subtransaction.hxx
00005  *
00006  *   DESCRIPTION
00007  *      definition of the pqxx::subtransaction class.
00008  *   pqxx::subtransaction is a nested transaction, i.e. one within a transaction
00009  *   DO NOT INCLUDE THIS FILE DIRECTLY; include pqxx/subtransaction instead.
00010  *
00011  * Copyright (c) 2005-2006, Jeroen T. Vermeulen <jtv@xs4all.nl>
00012  *
00013  * See COPYING for copyright license.  If you did not receive a file called
00014  * COPYING with this source code, please notify the distributor of this mistake,
00015  * or contact the author.
00016  *
00017  *-------------------------------------------------------------------------
00018  */
00019 #include "pqxx/compiler-public.hxx"
00020 #include "pqxx/compiler-internal-pre.hxx"
00021 
00022 #include "pqxx/dbtransaction"
00023 
00024 
00025 
00026 /* Methods tested in eg. self-test program test1 are marked with "//[t1]"
00027  */
00028 
00029 
00030 namespace pqxx
00031 {
00032 
00037 
00038 class PQXX_LIBEXPORT subtransaction :
00039   public internal::transactionfocus,
00040   public dbtransaction
00041 {
00042 public:
00043   explicit subtransaction(dbtransaction &T,
00044         const PGSTD::string &Name=PGSTD::string());                     //[t88]
00045 
00046 private:
00047   virtual void do_begin();                                              //[t88]
00048   virtual void do_commit();                                             //[t88]
00049   virtual void do_abort();                                              //[t88]
00050 
00051   void check_backendsupport() const;
00052 
00053   dbtransaction &m_parent;
00054 };
00055 
00057 
00058 }
00059 
00060 
00061 #include "pqxx/compiler-internal-post.hxx"

Generated on Sat May 27 17:33:49 2006 for libpqxx by  doxygen 1.4.6