summaryrefslogtreecommitdiff
path: root/libpqpp/pq-connection.h
diff options
context:
space:
mode:
authorDan Goodliffe <dan@randomdan.homeip.net>2015-12-29 05:16:51 +0000
committerDan Goodliffe <dan@randomdan.homeip.net>2015-12-29 06:00:08 +0000
commitfd9ad6023012494356829e9b7642ef4ec07f30a3 (patch)
tree28e8f424645dbd6e39863c5dd9531509740ad913 /libpqpp/pq-connection.h
parentTidy up (diff)
downloadlibdbpp-postgresql-fd9ad6023012494356829e9b7642ef4ec07f30a3.tar.bz2
libdbpp-postgresql-fd9ad6023012494356829e9b7642ef4ec07f30a3.tar.xz
libdbpp-postgresql-fd9ad6023012494356829e9b7642ef4ec07f30a3.zip
Improve and centralise transaction handling logic
Diffstat (limited to 'libpqpp/pq-connection.h')
-rw-r--r--libpqpp/pq-connection.h10
1 files changed, 3 insertions, 7 deletions
diff --git a/libpqpp/pq-connection.h b/libpqpp/pq-connection.h
index 65fd7b0..59b200c 100644
--- a/libpqpp/pq-connection.h
+++ b/libpqpp/pq-connection.h
@@ -17,11 +17,9 @@ namespace PQ {
Connection(const std::string & info);
~Connection();
- void finish() const override;
- int beginTx() const override;
- int commitTx() const override;
- int rollbackTx() const override;
- bool inTx() const override;
+ void beginTxInt() override;
+ void commitTxInt() override;
+ void rollbackTxInt() override;
void ping() const override;
void execute(const std::string & sql) override;
DB::BulkDeleteStyle bulkDeleteStyle() const override;
@@ -44,9 +42,7 @@ namespace PQ {
private:
static bool checkResultInt(PGresult * res, int expected, int alternative);
- mutable unsigned int txDepth;
mutable unsigned int pstmntNo;
- mutable bool rolledback;
};
}