transaction.h
Go to the documentation of this file.00001
00002
00003 #ifndef _LIBGDAMM_TRANSACTION_H
00004 #define _LIBGDAMM_TRANSACTION_H
00005
00006 #include <glibmm.h>
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030 #include <glibmm/object.h>
00031 #include <libgda/gda-transaction.h>
00032
00033
00034 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00035 typedef struct _GdaTransaction GdaTransaction;
00036 typedef struct _GdaTransactionClass GdaTransactionClass;
00037 #endif
00038
00039
00040 namespace Gnome
00041 {
00042
00043 namespace Gda
00044 { class Transaction_Class; }
00045
00046 }
00047 namespace Gnome
00048 {
00049
00050 namespace Gda
00051 {
00052
00058 enum TransactionIsolation
00059 {
00060 TRANSACTION_ISOLATION_UNKNOWN,
00061 TRANSACTION_ISOLATION_READ_COMMITTED,
00062 TRANSACTION_ISOLATION_READ_UNCOMMITTED,
00063 TRANSACTION_ISOLATION_REPEATABLE_READ,
00064 TRANSACTION_ISOLATION_SERIALIZABLE
00065 };
00066
00067 }
00068
00069 }
00070
00071
00072 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00073 namespace Glib
00074 {
00075
00076 template <>
00077 class Value<Gnome::Gda::TransactionIsolation> : public Glib::Value_Enum<Gnome::Gda::TransactionIsolation>
00078 {
00079 public:
00080 static GType value_type() G_GNUC_CONST;
00081 };
00082
00083 }
00084 #endif
00085
00086
00087 namespace Gnome
00088 {
00089
00090 namespace Gda
00091 {
00092
00093
00094 class Transaction : public Glib::Object
00095 {
00096
00097 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00098
00099 public:
00100 typedef Transaction CppObjectType;
00101 typedef Transaction_Class CppClassType;
00102 typedef GdaTransaction BaseObjectType;
00103 typedef GdaTransactionClass BaseClassType;
00104
00105 private: friend class Transaction_Class;
00106 static CppClassType transaction_class_;
00107
00108 private:
00109
00110 Transaction(const Transaction&);
00111 Transaction& operator=(const Transaction&);
00112
00113 protected:
00114 explicit Transaction(const Glib::ConstructParams& construct_params);
00115 explicit Transaction(GdaTransaction* castitem);
00116
00117 #endif
00118
00119 public:
00120 virtual ~Transaction();
00121
00122 #ifndef DOXYGEN_SHOULD_SKIP_THIS
00123 static GType get_type() G_GNUC_CONST;
00124 static GType get_base_type() G_GNUC_CONST;
00125 #endif
00126
00128 GdaTransaction* gobj() { return reinterpret_cast<GdaTransaction*>(gobject_); }
00129
00131 const GdaTransaction* gobj() const { return reinterpret_cast<GdaTransaction*>(gobject_); }
00132
00134 GdaTransaction* gobj_copy();
00135
00136 private:
00137
00138 protected:
00139 explicit Transaction(const Glib::ustring& name = Glib::ustring());
00140
00141
00142 public:
00143
00144 static Glib::RefPtr<Transaction> create(const Glib::ustring& name);
00145
00146
00147 TransactionIsolation get_isolation_level() const;
00148
00149 void set_isolation_level(GdaTransactionIsolation level);
00150
00151
00152 Glib::ustring get_name() const;
00153
00154 void set_name(const Glib::ustring& name);
00155
00156
00157 public:
00158
00159 public:
00160
00161
00162 protected:
00163
00164
00165
00166
00167
00168 };
00169
00170 }
00171 }
00172
00173
00174 namespace Glib
00175 {
00181 Glib::RefPtr<Gnome::Gda::Transaction> wrap(GdaTransaction* object, bool take_copy = false);
00182 }
00183
00184
00185 #endif
00186