Scorum
chain_api.hpp
Go to the documentation of this file.
1 #pragma once
2 
3 #define API_CHAIN "chain_api"
4 
5 #include <memory>
6 #include <fc/api.hpp>
8 
9 namespace scorum {
10 
11 namespace chain {
12 class database;
13 }
14 
15 namespace app {
16 
17 struct api_context;
18 
19 enum class reward_fund_type
20 {
24 };
25 
29 class chain_api : public std::enable_shared_from_this<chain_api>
30 {
31 public:
32  chain_api(const api_context& a);
33 
34  void on_api_startup();
35 
37 
39 
40  // money properties
42 
44 
45 private:
46  chain::database& _db;
47 };
48 }
49 }
50 
52  (content_reward_fund_scr)(content_reward_fund_sp)(content_fifa_world_cup_2018_bounty_reward_fund))
53 
54 FC_API(scorum::app::chain_api, (get_chain_properties)(get_next_scheduled_hardfork)(get_reward_fund)(get_chain_capital))
The chain_api class shows blockchain entrails.
Definition: chain_api.hpp:30
chain_properties_api_obj get_chain_properties() const
Definition: chain_api.cpp:31
chain_api(const api_context &a)
Definition: chain_api.cpp:22
reward_fund_api_obj get_reward_fund(reward_fund_type) const
Definition: chain_api.cpp:75
scheduled_hardfork_api_obj get_next_scheduled_hardfork() const
Definition: chain_api.cpp:64
chain_capital_api_obj get_chain_capital() const
Definition: chain_api.cpp:105
tracks the blockchain state in an extensible manner
Definition: database.hpp:52
FC_REFLECT_ENUM(scorum::protocol::game_status,(created)(started)(finished)(resolved)(expired)(cancelled)) namespace fc
Definition: game_status.hpp:18
Definition: asset.cpp:15