libfossil
fsl::Context::Transaction Class Reference

A utility class for managing transactions for a Context-managed database (regardless of whether the checkout or repo db). More...

#include "fossil.hpp"

Public Member Functions

 Transaction (Context &cx)
 Starts a transaction in cx.db(). More...
 
 ~Transaction () throw ()
 If commit() has not been called, this rolls back the transaction, otherwise it does nothing. More...
 
void commit ()
 Commits the transaction resp. More...
 

Detailed Description

A utility class for managing transactions for a Context-managed database (regardless of whether the checkout or repo db).

Definition at line 1334 of file fossil.hpp.

Constructor & Destructor Documentation

fsl::Context::Transaction::Transaction ( Context cx)

Starts a transaction in cx.db().

Throws on error.

fsl::Context::Transaction::~Transaction ( )
throw (
)

If commit() has not been called, this rolls back the transaction, otherwise it does nothing.

Member Function Documentation

void fsl::Context::Transaction::commit ( )

Commits the transaction resp.

pushes this level of the transaction stack off the stack.


The documentation for this class was generated from the following file: