Kagome
Polkadot Runtime Engine in C++17
runtime_upgrade_tracker.hpp
Go to the documentation of this file.
1 
6 #ifndef KAGOME_CORE_RUNTIME_RUNTIME_UPGRADE_TRACKER_HPP
7 #define KAGOME_CORE_RUNTIME_RUNTIME_UPGRADE_TRACKER_HPP
8 
9 #include "outcome/outcome.hpp"
10 #include "primitives/common.hpp"
11 #include "storage/trie/types.hpp"
12 
13 namespace kagome::runtime {
14 
20  public:
21  virtual ~RuntimeUpgradeTracker() = default;
22 
27  virtual outcome::result<storage::trie::RootHash> getLastCodeUpdateState(
28  const primitives::BlockInfo &block) = 0;
29 
30  virtual outcome::result<primitives::BlockInfo> getLastCodeUpdateBlockInfo(
31  const storage::trie::RootHash &state) const = 0;
32  };
33 
35 
36 } // namespace kagome::runtime
37 
39 
40 #endif // KAGOME_CORE_RUNTIME_RUNTIME_UPGRADE_TRACKER_HPP
virtual outcome::result< primitives::BlockInfo > getLastCodeUpdateBlockInfo(const storage::trie::RootHash &state) const =0
virtual outcome::result< storage::trie::RootHash > getLastCodeUpdateState(const primitives::BlockInfo &block)=0
OUTCOME_HPP_DECLARE_ERROR(kagome::api, JRpcServerImpl::Error)