Kagome
Polkadot Runtime Engine in C++17
system_api.hpp
Go to the documentation of this file.
1 
6 #ifndef KAGOME_API_SYSTEMAPI
7 #define KAGOME_API_SYSTEMAPI
8 
10 #include "consensus/babe/babe.hpp"
11 #include "network/peer_manager.hpp"
12 #include "primitives/account.hpp"
13 
14 namespace kagome::api {
15 
19  class SystemApi {
20  public:
21  virtual ~SystemApi() = default;
22 
23  virtual std::shared_ptr<application::ChainSpec> getConfig() const = 0;
24 
25  virtual std::shared_ptr<consensus::babe::Babe> getBabe() const = 0;
26 
27  virtual std::shared_ptr<network::PeerManager> getPeerManager() const = 0;
28 
29  virtual outcome::result<primitives::AccountNonce> getNonceFor(
30  std::string_view account_address) const = 0;
31  };
32 
33 } // namespace kagome::api
34 
35 #endif // KAGOME_API_SYSTEMAPI
virtual std::shared_ptr< consensus::babe::Babe > getBabe() const =0
virtual std::shared_ptr< application::ChainSpec > getConfig() const =0
virtual outcome::result< primitives::AccountNonce > getNonceFor(std::string_view account_address) const =0
virtual std::shared_ptr< network::PeerManager > getPeerManager() const =0
virtual ~SystemApi()=default