aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Makefile.am1
-rw-r--r--src/init.h13
-rw-r--r--src/node/context.h23
3 files changed, 25 insertions, 12 deletions
diff --git a/src/Makefile.am b/src/Makefile.am
index 82cc19d57c..f4c7feed72 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -157,6 +157,7 @@ BITCOIN_CORE_H = \
netmessagemaker.h \
node/coin.h \
node/coinstats.h \
+ node/context.h \
node/psbt.h \
node/transaction.h \
noui.h \
diff --git a/src/init.h b/src/init.h
index 099e96a161..f490a2cc50 100644
--- a/src/init.h
+++ b/src/init.h
@@ -7,21 +7,10 @@
#define BITCOIN_INIT_H
#include <memory>
+#include <node/context.h>
#include <string>
#include <util/system.h>
-namespace interfaces {
-class Chain;
-class ChainClient;
-} // namespace interfaces
-
-//! Pointers to interfaces used during init and destroyed on shutdown.
-struct NodeContext
-{
- std::unique_ptr<interfaces::Chain> chain;
- std::vector<std::unique_ptr<interfaces::ChainClient>> chain_clients;
-};
-
namespace boost
{
class thread_group;
diff --git a/src/node/context.h b/src/node/context.h
new file mode 100644
index 0000000000..3dd90ba961
--- /dev/null
+++ b/src/node/context.h
@@ -0,0 +1,23 @@
+// Copyright (c) 2019 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_NODE_CONTEXT_H
+#define BITCOIN_NODE_CONTEXT_H
+
+#include <memory>
+#include <vector>
+
+namespace interfaces {
+class Chain;
+class ChainClient;
+} // namespace interfaces
+
+//! Pointers to interfaces used during init and destroyed on shutdown.
+struct NodeContext
+{
+ std::unique_ptr<interfaces::Chain> chain;
+ std::vector<std::unique_ptr<interfaces::ChainClient>> chain_clients;
+};
+
+#endif // BITCOIN_NODE_CONTEXT_H