Bitcoin Core 28.99.0
P2P Digital Currency
server_util.h
Go to the documentation of this file.
1// Copyright (c) 2021-2022 The Bitcoin Core developers
2// Distributed under the MIT software license, see the accompanying
3// file COPYING or http://www.opensource.org/licenses/mit-license.php.
4
5#ifndef BITCOIN_RPC_SERVER_UTIL_H
6#define BITCOIN_RPC_SERVER_UTIL_H
7
8#include <any>
9
10class AddrMan;
11class ArgsManager;
13class CConnman;
14class CTxMemPool;
16class PeerManager;
17class BanMan;
18namespace node {
19struct NodeContext;
20} // namespace node
21namespace interfaces {
22class Mining;
23} // namespace interfaces
24
25node::NodeContext& EnsureAnyNodeContext(const std::any& context);
27CTxMemPool& EnsureAnyMemPool(const std::any& context);
29BanMan& EnsureAnyBanman(const std::any& context);
31ArgsManager& EnsureAnyArgsman(const std::any& context);
33ChainstateManager& EnsureAnyChainman(const std::any& context);
35CBlockPolicyEstimator& EnsureAnyFeeEstimator(const std::any& context);
40AddrMan& EnsureAnyAddrman(const std::any& context);
41
42#endif // BITCOIN_RPC_SERVER_UTIL_H
Stochastic address manager.
Definition: addrman.h:89
Definition: banman.h:59
The BlockPolicyEstimator is used for estimating the feerate needed for a transaction to be included i...
Definition: fees.h:149
Definition: net.h:1036
CTxMemPool stores valid-according-to-the-current-best-chain transactions that may be included in the ...
Definition: txmempool.h:304
Provides an interface for creating and interacting with one or two chainstates: an IBD chainstate gen...
Definition: validation.h:866
Interface giving clients (RPC, Stratum v2 Template Provider in the future) ability to create block te...
Definition: mining.h:64
Definition: messages.h:20
BanMan & EnsureBanman(const node::NodeContext &node)
Definition: server_util.cpp:44
ChainstateManager & EnsureAnyChainman(const std::any &context)
Definition: server_util.cpp:78
interfaces::Mining & EnsureMining(const node::NodeContext &node)
AddrMan & EnsureAnyAddrman(const std::any &context)
AddrMan & EnsureAddrman(const node::NodeContext &node)
ArgsManager & EnsureArgsman(const node::NodeContext &node)
Definition: server_util.cpp:57
CBlockPolicyEstimator & EnsureFeeEstimator(const node::NodeContext &node)
Definition: server_util.cpp:83
node::NodeContext & EnsureAnyNodeContext(const std::any &context)
Definition: server_util.cpp:21
BanMan & EnsureAnyBanman(const std::any &context)
Definition: server_util.cpp:52
CTxMemPool & EnsureMemPool(const node::NodeContext &node)
Definition: server_util.cpp:30
CTxMemPool & EnsureAnyMemPool(const std::any &context)
Definition: server_util.cpp:38
PeerManager & EnsurePeerman(const node::NodeContext &node)
CBlockPolicyEstimator & EnsureAnyFeeEstimator(const std::any &context)
Definition: server_util.cpp:91
CConnman & EnsureConnman(const node::NodeContext &node)
Definition: server_util.cpp:96
ChainstateManager & EnsureChainman(const node::NodeContext &node)
Definition: server_util.cpp:70
ArgsManager & EnsureAnyArgsman(const std::any &context)
Definition: server_util.cpp:65
NodeContext struct containing references to chain state and connection state.
Definition: context.h:56