Scorum
advertising_auction.hpp
Go to the documentation of this file.
1 #pragma once
2 #include <vector>
5 
6 namespace scorum {
7 namespace chain {
8 
11 using protocol::asset;
12 struct dynamic_global_property_service_i;
13 struct advertising_property_service_i;
14 template <budget_type> struct adv_budget_service_i;
15 
20 {
21 public:
23  advertising_property_service_i& adv_props_svc,
26 
27  void run_round();
28 
29  static std::vector<asset> calculate_bets(const std::vector<asset>& per_blocks,
30  const std::vector<percent_type>& coeffs);
31 
32 private:
33  template <budget_type budget_type_v>
34  void run_round(adv_budget_service_i<budget_type_v>& budget_svc, const std::vector<percent_type>& coeffs);
35 
36 private:
38  advertising_property_service_i& _adv_props_svc;
41 };
42 }
43 }
advertising_auction(dynamic_global_property_service_i &dprops_svc, advertising_property_service_i &adv_props_svc, adv_budget_service_i< budget_type::post > &post_budget_svc, adv_budget_service_i< budget_type::banner > &banner_budget_svc)
static std::vector< asset > calculate_bets(const std::vector< asset > &per_blocks, const std::vector< percent_type > &coeffs)
uint16_t percent_type
Definition: types.hpp:69
Definition: asset.cpp:15