From ca65e5ad8f1e6395c64f19f7cfea267d24f55bf3 Mon Sep 17 00:00:00 2001 From: JoelKatz Date: Wed, 31 Oct 2012 16:02:21 -0700 Subject: [PATCH] Add transactions to the tracked class list. --- src/Transaction.cpp | 2 ++ src/Transaction.h | 5 ++++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/Transaction.cpp b/src/Transaction.cpp index 2fca627427..c4dbd435c9 100644 --- a/src/Transaction.cpp +++ b/src/Transaction.cpp @@ -13,6 +13,8 @@ #include "SerializedTransaction.h" #include "Log.h" +DECLARE_INSTANCE(Transaction); + Transaction::Transaction(SerializedTransaction::ref sit, bool bValidate) : mInLedger(0), mStatus(INVALID), mResult(temUNCERTAIN), mTransaction(sit) { diff --git a/src/Transaction.h b/src/Transaction.h index 8d14654e29..ea049b5279 100644 --- a/src/Transaction.h +++ b/src/Transaction.h @@ -21,6 +21,7 @@ #include "SHAMap.h" #include "SerializedTransaction.h" #include "TransactionErr.h" +#include "InstanceCounter.h" class Database; @@ -37,8 +38,10 @@ enum TransStatus INCOMPLETE = 8 // needs more signatures }; +DEFINE_INSTANCE(Transaction); + // This class is for constructing and examining transactions. Transactions are static so manipulation functions are unnecessary. -class Transaction : public boost::enable_shared_from_this +class Transaction : public boost::enable_shared_from_this, private IS_INSTANCE(Transaction) { public: typedef boost::shared_ptr pointer;