aboutsummaryrefslogtreecommitdiff
path: root/src/index/txindex.h
diff options
context:
space:
mode:
authorJim Posen <jim.posen@gmail.com>2018-05-15 15:45:20 -0700
committerJim Posen <jim.posen@gmail.com>2018-06-04 19:22:24 -0700
commitf376a4924109af2496b5fd16a787299eb039f1c8 (patch)
tree925e460c230e5c061b21e1782e5ec56944cca29e /src/index/txindex.h
parent61a1226d87d80234b2be123c5cad07534c318cfb (diff)
downloadbitcoin-f376a4924109af2496b5fd16a787299eb039f1c8.tar.xz
index: Generalize logged statements in BaseIndex.
Diffstat (limited to 'src/index/txindex.h')
-rw-r--r--src/index/txindex.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/index/txindex.h b/src/index/txindex.h
index f38d845998..29626332ab 100644
--- a/src/index/txindex.h
+++ b/src/index/txindex.h
@@ -57,6 +57,9 @@ protected:
virtual BaseIndexDB& GetDB() const = 0;
+ /// Get the name of the index for display in logs.
+ virtual const char* GetName() const = 0;
+
public:
/// Destructor interrupts sync thread if running and blocks until it exits.
virtual ~BaseIndex();
@@ -96,6 +99,8 @@ protected:
BaseIndexDB& GetDB() const override;
+ const char* GetName() const override { return "txindex"; }
+
public:
/// Constructs the index, which becomes available to be queried.
explicit TxIndex(std::unique_ptr<TxIndexDB> db);