diff options
author | Ryan Ofsky <ryan@ofsky.org> | 2022-01-13 07:55:18 -0500 |
---|---|---|
committer | Ryan Ofsky <ryan@ofsky.org> | 2022-07-18 13:39:55 -0500 |
commit | a0b5b4ae5a24536d333cbce2ea584f2d935c651f (patch) | |
tree | 71fbd31c68142216d20ff3414d9360feee5baa3e /src/kernel/chain.h | |
parent | 8d4a058ac421da838422da127aac71abf83a49f6 (diff) |
interfaces, refactor: Add more block information to block connected notifications
Add new interfaces::BlockInfo struct to be able to pass extra block
information (file and undo information) to indexes which they are
updated to use high level interfaces::Chain notifications.
This commit does not change behavior in any way.
Diffstat (limited to 'src/kernel/chain.h')
-rw-r--r-- | src/kernel/chain.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/kernel/chain.h b/src/kernel/chain.h new file mode 100644 index 0000000000..f0750f8266 --- /dev/null +++ b/src/kernel/chain.h @@ -0,0 +1,19 @@ +// Copyright (c) 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_KERNEL_CHAIN_H +#define BITCOIN_KERNEL_CHAIN_H + +class CBlock; +class CBlockIndex; +namespace interfaces { +struct BlockInfo; +} // namespace interfaces + +namespace kernel { +//! Return data from block index. +interfaces::BlockInfo MakeBlockInfo(const CBlockIndex* block_index, const CBlock* data = nullptr); +} // namespace kernel + +#endif // BITCOIN_KERNEL_CHAIN_H |