Scorum
Classes | Namespaces | Typedefs | Functions
market.hpp File Reference
#include <fc/static_variant.hpp>
#include <scorum/protocol/betting/wincase.hpp>
#include <scorum/protocol/betting/market_kind.hpp>
#include <scorum/protocol/config.hpp>
#include <boost/range/algorithm/transform.hpp>
#include <scorum/protocol/betting/wincase_comparison.hpp>
#include <scorum/protocol/betting/market_comparison.hpp>

Go to the source code of this file.

Classes

struct  scorum::protocol::over_under_market< kind, tag >
 
struct  scorum::protocol::score_yes_no_market< kind, tag >
 
struct  scorum::protocol::yes_no_market< kind, tag >
 

Namespaces

 scorum
 
 scorum::protocol
 
 fc
 

Typedefs

using scorum::protocol::result_home = yes_no_market< market_kind::result, home_tag >
 
using scorum::protocol::result_draw = yes_no_market< market_kind::result, draw_tag >
 
using scorum::protocol::result_away = yes_no_market< market_kind::result, away_tag >
 
using scorum::protocol::round_home = yes_no_market< market_kind::round >
 
using scorum::protocol::handicap = over_under_market< market_kind::handicap >
 
using scorum::protocol::correct_score_home = yes_no_market< market_kind::correct_score, home_tag >
 
using scorum::protocol::correct_score_draw = yes_no_market< market_kind::correct_score, draw_tag >
 
using scorum::protocol::correct_score_away = yes_no_market< market_kind::correct_score, away_tag >
 
using scorum::protocol::correct_score = score_yes_no_market< market_kind::correct_score >
 
using scorum::protocol::goal_home = yes_no_market< market_kind::goal, home_tag >
 
using scorum::protocol::goal_both = yes_no_market< market_kind::goal, both_tag >
 
using scorum::protocol::goal_away = yes_no_market< market_kind::goal, away_tag >
 
using scorum::protocol::total = over_under_market< market_kind::total >
 
using scorum::protocol::total_goals_home = over_under_market< market_kind::total_goals, home_tag >
 
using scorum::protocol::total_goals_away = over_under_market< market_kind::total_goals, away_tag >
 
using scorum::protocol::market_type = fc::static_variant< result_home, result_draw, result_away, round_home, handicap, correct_score_home, correct_score_draw, correct_score_away, correct_score, goal_home, goal_both, goal_away, total, total_goals_home, total_goals_away >
 
using scorum::protocol::wincase_type = fc::static_variant< result_home::yes, result_home::no, result_draw::yes, result_draw::no, result_away::yes, result_away::no, round_home::yes, round_home::no, handicap::over, handicap::under, correct_score_home::yes, correct_score_home::no, correct_score_draw::yes, correct_score_draw::no, correct_score_away::yes, correct_score_away::no, correct_score::yes, correct_score::no, goal_home::yes, goal_home::no, goal_both::yes, goal_both::no, goal_away::yes, goal_away::no, total::over, total::under, total_goals_home::over, total_goals_home::under, total_goals_away::over, total_goals_away::under >
 

Functions

std::pair< wincase_type, wincase_type > scorum::protocol::create_wincases (const market_type &market)
 
wincase_type scorum::protocol::create_opposite (const wincase_type &wincase)
 
market_type scorum::protocol::create_market (const wincase_type &wincase)
 
bool scorum::protocol::has_trd_state (const market_type &market)
 
bool scorum::protocol::match_wincases (const wincase_type &lhs, const wincase_type &rhs)
 
market_kind scorum::protocol::get_market_kind (const wincase_type &wincase)
 
template<typename T >
std::set< market_kind > scorum::protocol::get_markets_kind (const T &markets)
 
template<typename T >
bool scorum::protocol::is_belong_markets (const wincase_type &wincase, const T &markets)
 
template<>
void fc::to_variant (const wincase_type &wincase, fc::variant &var)
 
template<>
void fc::from_variant (const fc::variant &var, wincase_type &wincase)
 
template<>
void fc::to_variant (const market_type &market, fc::variant &var)
 
template<>
void fc::from_variant (const fc::variant &var, market_type &market)