forked from blue/lmdbal
Some refactor
This commit is contained in:
parent
bfb1d007ad
commit
3ae1fd15c0
5 changed files with 50 additions and 40 deletions
|
@ -27,6 +27,7 @@ class CursorCommon;
|
|||
class Transaction {
|
||||
friend class Base;
|
||||
friend class StorageCommon;
|
||||
friend class CursorCommon;
|
||||
public:
|
||||
explicit Transaction();
|
||||
explicit Transaction(Transaction&& other);
|
||||
|
@ -44,10 +45,10 @@ protected:
|
|||
void closeCursors();
|
||||
|
||||
protected:
|
||||
TransactionID txn; /**<\brief Transaction inner handler*/
|
||||
bool active; /**<\brief Transaction state*/
|
||||
const Base* parent; /**<\brief Pointer to the database this transaction belongs to*/
|
||||
std::map<uint32_t, CursorCommon*> cursors; /**<\brief a collection of cursors curently opened under this transaction*/
|
||||
TransactionID txn; /**<\brief Transaction inner handler*/
|
||||
bool active; /**<\brief Transaction state*/
|
||||
const Base* parent; /**<\brief Pointer to the database this transaction belongs to*/
|
||||
mutable std::map<uint32_t, CursorCommon*> cursors; /**<\brief a collection of cursors curently opened under this transaction*/
|
||||
};
|
||||
|
||||
class WriteTransaction : public Transaction {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue