veriblock-pop-cpp
C++11 Libraries for leveraging VeriBlock Proof-Of-Proof blockchain technology.
check_pubdata.hpp
1// Copyright (c) 2019-2022 Xenios SEZC
2// https://www.veriblock.org
3// Distributed under the MIT software license, see the accompanying
4// file LICENSE or http://www.opensource.org/licenses/mit-license.php.
5
6#ifndef VERIBLOCK_POP_CPP_CHECK_PUBDATA_HPP
7#define VERIBLOCK_POP_CPP_CHECK_PUBDATA_HPP
8
9#include <veriblock/pop/blockchain/alt_block_tree.hpp>
10
11namespace altintegration {
12
16struct CheckPublicationData : public Command {
17 ~CheckPublicationData() override = default;
18
20 AltBlockTree& tree,
21 AltBlock::hash_t endorsed_hash);
22
23 bool Execute(ValidationState& state) noexcept override;
24
25 void UnExecute() noexcept override {
26 // This command does not modify current state, thus UnExecute is a no-op
27 }
28
29 private:
30 const PublicationData pub;
31 const AltBlock::hash_t endorsed_hash;
32 AltBlockTree* tree = nullptr;
33};
34
35} // namespace altintegration
36
37#endif // VERIBLOCK_POP_CPP_CHECK_PUBDATA_HPP
Class that is used for storing validation state.
Defines logging helpers.
Definition: block.hpp:14
Represents simplified view on Altchain's block tree, maintains VBK tree and BTC tree.
A command which performs stateful check of PublicationData stored in ATV.
Publication data about ALT block inside VBK blockchain.