aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/mempool.h
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2022-03-16 09:25:50 +0100
committerMarcoFalke <falke.marco@gmail.com>2022-03-16 09:26:19 +0100
commit310ba924949b0052105a7937ac69d65a3864692b (patch)
tree927b2fbc215d2c7b2b4dd5a7420e49c035d9371c /src/rpc/mempool.h
parent760651214cd205b91804bc1c40a31c614d3aa26c (diff)
parentfad4c8934c7b4342076bd01daa4abf4d83617b17 (diff)
Merge bitcoin/bitcoin#24537: rpc: Split mempool RPCs from blockchain.cpp
fad4c8934c7b4342076bd01daa4abf4d83617b17 Add RegisterMempoolRPCCommands helper (MarcoFalke) fafd40b5413aea5f8ec47c24fdb2ccc702e7cdd7 refactor: Avoid int64_t -> size_t -> int64_t conversion (MarcoFalke) fa2a5f301aa678aa7b6be4bb7987f2bcbdaf2be2 rpc: Move mempool RPCs to new file (MarcoFalke) Pull request description: The `blockchain.cpp` file is quite large. This makes it harder to navigate and increases the memory required to compile. Improve on both issues by splitting up the mempool RPCs to a separate file. ACKs for top commit: promag: Code review ACK fad4c8934c7b4342076bd01daa4abf4d83617b17. theStack: Code-review ACK fad4c8934c7b4342076bd01daa4abf4d83617b17 🏞️ Tree-SHA512: 7f13168ea2cbea51eaef05ca1604fddc919480a2128ec7fa6b1f9365ec5e4822c3df93eb408a19f038c627f2309fa282b9f7f7ec45e5e661fc728f6b33157f89
Diffstat (limited to 'src/rpc/mempool.h')
-rw-r--r--src/rpc/mempool.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/rpc/mempool.h b/src/rpc/mempool.h
new file mode 100644
index 0000000000..229d7d52dd
--- /dev/null
+++ b/src/rpc/mempool.h
@@ -0,0 +1,17 @@
+// Copyright (c) 2017-2022 The Bitcoin Core developers
+// Distributed under the MIT software license, see the accompanying
+// file COPYING or http://www.opensource.org/licenses/mit-license.php.
+
+#ifndef BITCOIN_RPC_MEMPOOL_H
+#define BITCOIN_RPC_MEMPOOL_H
+
+class CTxMemPool;
+class UniValue;
+
+/** Mempool information to JSON */
+UniValue MempoolInfoToJSON(const CTxMemPool& pool);
+
+/** Mempool to JSON */
+UniValue MempoolToJSON(const CTxMemPool& pool, bool verbose = false, bool include_mempool_sequence = false);
+
+#endif // BITCOIN_RPC_MEMPOOL_H