Scorum
Namespaces | Classes | Typedefs | Enumerations | Functions
scorum::protocol Namespace Reference

Namespaces

 atomicswap
 
 detail
 

Classes

struct  wincases_builder
 
struct  market_builder
 
struct  asset
 
struct  authority
 
struct  base_operation
 
struct  virtual_operation
 
struct  soccer_game
 
struct  hockey_game
 
struct  over_under_market
 
struct  score_yes_no_market
 
struct  yes_no_market
 
struct  over_under_wincase
 
struct  score_yes_no_wincase
 
struct  yes_no_wincase
 
struct  signed_block
 
struct  block_header
 
struct  signed_block_header
 
struct  chain_properties
 
struct  beneficiary_route_type
 
struct  comment_payout_beneficiaries
 
class  odds
 
struct  operation_info
 
struct  operation_validate_visitor
 
struct  operation_get_required_auth_visitor
 
struct  committee_i
 
struct  registration_committee_i
 
struct  development_committee_i
 
struct  committee
 
struct  proposal_committee_operation
 
struct  proposal_base_operation
 
struct  registration_committee_add_member_operation
 
struct  registration_committee_exclude_member_operation
 
struct  registration_committee_change_quorum_operation
 
struct  development_committee_add_member_operation
 
struct  development_committee_exclude_member_operation
 
struct  development_committee_change_quorum_operation
 
struct  development_committee_withdraw_vesting_operation
 
struct  development_committee_transfer_operation
 
struct  development_committee_empower_advertising_moderator_operation
 
struct  development_committee_empower_betting_moderator_operation
 
struct  base_development_committee_change_budgets_auction_properties_operation
 
struct  development_committee_change_budgets_auction_properties_operation
 
struct  development_committee_change_betting_resolve_delay_operation
 
struct  account_create_operation
 Creates new account. More...
 
struct  account_create_with_delegation_operation
 Creates new account with delegation. More...
 
struct  account_create_by_committee_operation
 Creates new account by registration committee. More...
 
struct  account_update_operation
 Updates account keys or/and metadata. More...
 
struct  comment_operation
 Posts comment. More...
 
struct  comment_options_operation
 Updates comment options. More...
 
struct  prove_authority_operation
 Proves authority to remove challenge. More...
 
struct  delete_comment_operation
 Deletes comment. More...
 
struct  vote_operation
 Votes for content. More...
 
struct  transfer_operation
 Transfers SCR from one account to another. More...
 
struct  escrow_transfer_operation
 Starts escrow transfer. More...
 
struct  escrow_approve_operation
 Approves escrow transaction. More...
 
struct  escrow_dispute_operation
 Starts escrow dispute. More...
 
struct  escrow_release_operation
 Releases escrow transaction. More...
 
struct  transfer_to_scorumpower_operation
 Converts SCR to SP. More...
 
struct  withdraw_scorumpower_operation
 Starts vesting withdraw. More...
 
struct  set_withdraw_scorumpower_route_to_account_operation
 Setup a versting withdraw to another account. More...
 
struct  set_withdraw_scorumpower_route_to_dev_pool_operation
 Setup a versting withdraw to development pool. More...
 
struct  witness_update_operation
 Updates account to witness. More...
 
struct  account_witness_vote_operation
 Votes for witness. More...
 
struct  account_witness_proxy_operation
 Sets witness proxy for account. More...
 
struct  request_account_recovery_operation
 Requests account recovery. More...
 
struct  recover_account_operation
 Recovers an account to a new authority using a previous authority. More...
 
struct  change_recovery_account_operation
 Changes recovery account. Will be changed in 30 days. More...
 
struct  decline_voting_rights_operation
 
struct  delegate_scorumpower_operation
 Delegates scorumpower from one account to the other. More...
 
struct  delegate_sp_from_reg_pool_operation
 
struct  create_budget_operation
 Creates advertising budget. More...
 
struct  update_budget_operation
 Updates advertising budget metadata. More...
 
struct  close_budget_operation
 Closes advertising budget, remaining funds will be returned to creator. More...
 
struct  close_budget_by_advertising_moderator_operation
 Closes advertising budget by moderator, remaining funds will be returned to creator. More...
 
struct  proposal_create_operation
 Creates new committee proposal. More...
 
struct  proposal_vote_operation
 Votes for committee proposal. More...
 
struct  atomicswap_initiate_operation
 Initiates atomicswap operation. More...
 
struct  atomicswap_redeem_operation
 Redeems atomicswap operation. More...
 
struct  atomicswap_refund_operation
 Refunds atomicswap operation. More...
 
struct  odds_input
 rational number More...
 
struct  create_game_operation
 This operation creates game object. More...
 
struct  cancel_game_operation
 This operation canceling game. More...
 
struct  update_game_markets_operation
 This operation updates game markets list. More...
 
struct  update_game_start_time_operation
 This operation updates game start time. More...
 
struct  post_game_results_operation
 With this operation moderator provides game results(wincases) More...
 
struct  post_bet_operation
 This operation creates bet. More...
 
struct  cancel_pending_bets_operation
 This operation cancel unmatched bets by id. More...
 
struct  create_nft_operation
 This operation create new NFT. More...
 
struct  update_nft_meta_operation
 This operation update NFT metadata. More...
 
struct  adjust_nft_experience_operation
 This operation adjust NFT experience. More...
 
struct  update_nft_name_operation
 This operation update NFT name. More...
 
struct  create_game_round_operation
 This operation create new game round. More...
 
struct  update_game_round_result_operation
 This operation update game round results. More...
 
struct  author_reward_operation
 
struct  curation_reward_operation
 
struct  comment_reward_operation
 
struct  acc_finished_vesting_withdraw_operation
 
struct  devpool_finished_vesting_withdraw_operation
 
struct  acc_to_acc_vesting_withdraw_operation
 
struct  devpool_to_acc_vesting_withdraw_operation
 
struct  acc_to_devpool_vesting_withdraw_operation
 
struct  devpool_to_devpool_vesting_withdraw_operation
 
struct  shutdown_witness_operation
 
struct  witness_miss_block_operation
 
struct  hardfork_operation
 
struct  comment_payout_update_operation
 
struct  return_scorumpower_delegation_operation
 
struct  comment_benefficiary_reward_operation
 
struct  producer_reward_operation
 
struct  active_sp_holders_reward_operation
 
struct  active_sp_holders_reward_legacy_operation
 
struct  expired_contract_refund_operation
 
struct  proposal_virtual_operation
 
struct  budget_outgo_operation
 
struct  budget_owner_income_operation
 
struct  budget_closing_operation
 
struct  bets_matched_operation
 
struct  game_status_changed_operation
 
struct  bet_resolved_operation
 
struct  bet_cancelled_operation
 
struct  bet_restored_operation
 
struct  bet_updated_operation
 
struct  sign_state
 
struct  transaction
 
struct  signed_transaction
 
struct  annotated_signed_transaction
 
struct  public_key_type
 
struct  extended_public_key_type
 
struct  extended_private_key_type
 
struct  version
 
struct  hardfork_version
 
struct  hardfork_version_vote
 
struct  is_market_op_visitor
 
struct  is_vop_visitor
 
struct  operation_get_required_quorum_visitor
 

Typedefs

typedef boost::multiprecision::int128_t int128_t
 
using asset_symbol_type = uint64_t
 
typedef flat_map< account_name_type, authority_weight_typeaccount_authority_map
 
typedef static_variant< void_t, version, hardfork_version_voteblock_header_extensions
 
typedef static_variant< void_tfuture_extensions
 
typedef flat_set< block_header_extensionsblock_header_extensions_type
 
typedef flat_set< future_extensionsextensions_type
 
using game_type = fc::static_variant< soccer_game, hockey_game >
 
using result_home = yes_no_market< market_kind::result, home_tag >
 
using result_draw = yes_no_market< market_kind::result, draw_tag >
 
using result_away = yes_no_market< market_kind::result, away_tag >
 
using round_home = yes_no_market< market_kind::round >
 
using handicap = over_under_market< market_kind::handicap >
 
using correct_score_home = yes_no_market< market_kind::correct_score, home_tag >
 
using correct_score_draw = yes_no_market< market_kind::correct_score, draw_tag >
 
using correct_score_away = yes_no_market< market_kind::correct_score, away_tag >
 
using correct_score = score_yes_no_market< market_kind::correct_score >
 
using goal_home = yes_no_market< market_kind::goal, home_tag >
 
using goal_both = yes_no_market< market_kind::goal, both_tag >
 
using goal_away = yes_no_market< market_kind::goal, away_tag >
 
using total = over_under_market< market_kind::total >
 
using total_goals_home = over_under_market< market_kind::total_goals, home_tag >
 
using total_goals_away = over_under_market< market_kind::total_goals, away_tag >
 
using 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 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 >
 
typedef static_variant< comment_payout_beneficiariescomment_options_extension
 
typedef flat_set< comment_options_extensioncomment_options_extensions_type
 
using odds_value_type = int32_t
 
using odds_fraction_type = utils::fraction< odds_value_type, odds_value_type >
 
using operation = fc::static_variant< vote_operation, comment_operation, transfer_operation, transfer_to_scorumpower_operation, withdraw_scorumpower_operation, account_create_by_committee_operation, account_create_operation, account_create_with_delegation_operation, account_update_operation, witness_update_operation, account_witness_vote_operation, account_witness_proxy_operation, delete_comment_operation, comment_options_operation, set_withdraw_scorumpower_route_to_account_operation, set_withdraw_scorumpower_route_to_dev_pool_operation, prove_authority_operation, request_account_recovery_operation, recover_account_operation, change_recovery_account_operation, escrow_approve_operation, escrow_dispute_operation, escrow_release_operation, escrow_transfer_operation, decline_voting_rights_operation, delegate_scorumpower_operation, create_budget_operation, close_budget_operation, proposal_vote_operation, proposal_create_operation, atomicswap_initiate_operation, atomicswap_redeem_operation, atomicswap_refund_operation, close_budget_by_advertising_moderator_operation, update_budget_operation, create_game_operation, cancel_game_operation, update_game_markets_operation, update_game_start_time_operation, post_game_results_operation, post_bet_operation, cancel_pending_bets_operation, delegate_sp_from_reg_pool_operation, create_nft_operation, update_nft_meta_operation, create_game_round_operation, update_game_round_result_operation, adjust_nft_experience_operation, update_nft_name_operation, author_reward_operation, comment_benefficiary_reward_operation, comment_payout_update_operation, comment_reward_operation, curation_reward_operation, hardfork_operation, producer_reward_operation, active_sp_holders_reward_operation, return_scorumpower_delegation_operation, shutdown_witness_operation, witness_miss_block_operation, expired_contract_refund_operation, acc_finished_vesting_withdraw_operation, devpool_finished_vesting_withdraw_operation, acc_to_acc_vesting_withdraw_operation, devpool_to_acc_vesting_withdraw_operation, acc_to_devpool_vesting_withdraw_operation, devpool_to_devpool_vesting_withdraw_operation, proposal_virtual_operation, budget_outgo_operation, budget_owner_income_operation, active_sp_holders_reward_legacy_operation, budget_closing_operation, bets_matched_operation, game_status_changed_operation, bet_resolved_operation, bet_cancelled_operation, bet_restored_operation, bet_updated_operation >
 
using development_committee_change_post_budgets_auction_properties_operation = development_committee_change_budgets_auction_properties_operation< budget_type::post >
 
using development_committee_change_banner_budgets_auction_properties_operation = development_committee_change_budgets_auction_properties_operation< budget_type::banner >
 
using proposal_operation = fc::static_variant< registration_committee_add_member_operation, registration_committee_exclude_member_operation, registration_committee_change_quorum_operation, development_committee_add_member_operation, development_committee_exclude_member_operation, development_committee_change_quorum_operation, development_committee_withdraw_vesting_operation, development_committee_transfer_operation, development_committee_empower_advertising_moderator_operation, development_committee_change_post_budgets_auction_properties_operation, development_committee_change_banner_budgets_auction_properties_operation, development_committee_empower_betting_moderator_operation, development_committee_change_betting_resolve_delay_operation >
 
typedef std::function< authority(const std::string &)> authority_getter
 
typedef fc::ecc::private_key private_key_type
 
typedef fc::sha256 chain_id_type
 
typedef fc::fixed_string_16 account_name_type
 
typedef fc::ripemd160 block_id_type
 
typedef fc::ripemd160 checksum_type
 
typedef fc::ripemd160 transaction_id_type
 
typedef fc::sha256 digest_type
 
typedef fc::ecc::compact_signature signature_type
 
typedef uint16_t authority_weight_type
 
typedef uint16_t percent_type
 
typedef int16_t vote_weight_type
 
using share_value_type = int64_t
 
using share_type = fc::safe< share_value_type >
 

Enumerations

enum class  game_status : uint8_t {
  created , started , finished , resolved ,
  expired , cancelled
}
 
enum class  market_kind : uint16_t {
  result , round , handicap , correct_score ,
  goal , total , total_goals
}
 
enum  quorum_type {
  none_quorum , add_member_quorum , exclude_member_quorum , base_quorum ,
  transfer_quorum , advertising_moderator_quorum , budgets_auction_properties_quorum , betting_moderator_quorum ,
  betting_resolve_delay_quorum
}
 
enum class  bet_resolve_kind : uint8_t { win , draw }
 
enum class  bet_kind : uint8_t { pending , matched }
 
enum class  curve_id { quadratic , linear , square_root , power1dot5 }
 
enum class  budget_type { post , banner }
 

Functions

bool is_valid_account_name (const std::string &name)
 
bool operator== (const authority &a, const authority &b)
 
const bf::map< bf::pair< soccer_game, std::set< market_kind > >, bf::pair< hockey_game, std::set< market_kind > > > game_markets (bf::make_pair< soccer_game >(std::set< market_kind >{ market_kind::result, market_kind::round, market_kind::handicap, market_kind::correct_score, market_kind::goal, market_kind::total, market_kind::total_goals }), bf::make_pair< hockey_game >(std::set< market_kind >{ market_kind::result, market_kind::goal }))
 
void validate_game (const game_type &game, const fc::flat_set< market_type > &markets)
 
void validate_markets (const fc::flat_set< market_type > &markets)
 
void validate_wincases (const fc::flat_set< wincase_type > &wincases)
 
void validate_wincase (const wincase_type &wincase)
 
void validate_if_wincase_in_game (const game_type &game, const wincase_type &wincase)
 
void validate_bet_ids (const fc::flat_set< int64_t > &bet_ids)
 
void validate_market (const market_type &market)
 
std::pair< wincase_type, wincase_typecreate_wincases (const market_type &market)
 
market_type create_market (const wincase_type &wincase)
 
wincase_type create_opposite (const wincase_type &wincase)
 
bool has_trd_state (const market_type &market)
 
bool match_wincases (const wincase_type &lhs, const wincase_type &rhs)
 
market_kind get_market_kind (const wincase_type &wincase)
 
fc::variant_object get_config ()
 
template<typename Stream >
Stream & operator<< (Stream &stream, const scorum::protocol::asset &a)
 
template<typename Stream >
Stream & operator>> (Stream &stream, scorum::protocol::asset &a)
 
template<typename AuthorityType >
void add_authority_accounts (flat_set< account_name_type > &result, const AuthorityType &a)
 
void validate_account_name (const std::string &name)
 
void validate_permlink (const std::string &permlink)
 
void validate_json_metadata (const std::string &json_metadata)
 
template<typename T >
std::set< market_kindget_markets_kind (const T &markets)
 
template<typename T >
bool is_belong_markets (const wincase_type &wincase, const T &markets)
 
template<market_kind kind, typename tag >
bool operator< (const over_under_market< kind, tag > &lhs, const over_under_market< kind, tag > &rhs)
 
template<market_kind kind, typename tag >
bool operator< (const yes_no_market< kind, tag > &lhs, const yes_no_market< kind, tag > &rhs)
 
template<market_kind kind, typename tag >
bool operator< (const score_yes_no_market< kind, tag > &lhs, const score_yes_no_market< kind, tag > &rhs)
 
template<bool side, market_kind kind, typename tag >
bool operator< (const over_under_wincase< side, kind, tag > &lhs, const over_under_wincase< side, kind, tag > &rhs)
 
template<bool side, market_kind kind, typename tag >
bool operator< (const yes_no_wincase< side, kind, tag > &lhs, const yes_no_wincase< side, kind, tag > &rhs)
 
template<bool side, market_kind kind, typename tag >
bool operator< (const score_yes_no_wincase< side, kind, tag > &lhs, const score_yes_no_wincase< side, kind, tag > &rhs)
 
 FC_DECLARE_DERIVED_EXCEPTION (tx_missing_active_auth, scorum::protocol::transaction_exception, 3010000, "missing required active authority") FC_DECLARE_DERIVED_EXCEPTION(tx_missing_owner_auth
 
missing required owner authority FC_DECLARE_DERIVED_EXCEPTION (tx_missing_posting_auth, scorum::protocol::transaction_exception, 3030000, "missing required posting authority") FC_DECLARE_DERIVED_EXCEPTION(tx_missing_other_auth
 
missing required owner authority missing required other authority FC_DECLARE_DERIVED_EXCEPTION (tx_irrelevant_sig, scorum::protocol::transaction_exception, 3050000, "irrelevant signature included") FC_DECLARE_DERIVED_EXCEPTION(tx_duplicate_sig
 
template<typename Stream >
Stream & operator<< (Stream &stream, const scorum::protocol::odds &o)
 
template<typename Stream >
Stream & operator>> (Stream &stream, scorum::protocol::odds &o)
 
bool is_market_operation (const operation &op)
 
bool is_virtual_operation (const operation &op)
 
void validate_quorum (quorum_type t, protocol::percent_type quorum)
 
void operation_validate (const proposal_operation &op)
 
protocol::percent_type operation_get_required_quorum (committee &committee_service, const proposal_operation &op)
 
void verify_authority (const std::vector< operation > &ops, const flat_set< public_key_type > &sigs, const authority_getter &get_active, const authority_getter &get_owner, const authority_getter &get_posting, uint32_t max_recursion=SCORUM_MAX_SIG_CHECK_DEPTH, bool allow_committe=false, const flat_set< account_name_type > &active_aprovals=flat_set< account_name_type >(), const flat_set< account_name_type > &owner_aprovals=flat_set< account_name_type >(), const flat_set< account_name_type > &posting_approvals=flat_set< account_name_type >())
 
bool is_asset_type (asset asset, asset_symbol_type symbol)
 
template<class T >
bool is_unique (const std::vector< T > &input)
 
bool operator== (const public_key_type &p1, const fc::ecc::public_key &p2)
 
bool operator== (const public_key_type &p1, const public_key_type &p2)
 
bool operator!= (const public_key_type &p1, const public_key_type &p2)
 
bool operator== (const extended_public_key_type &p1, const fc::ecc::extended_public_key &p2)
 
bool operator== (const extended_public_key_type &p1, const extended_public_key_type &p2)
 
bool operator!= (const extended_public_key_type &p1, const extended_public_key_type &p2)
 
bool operator== (const extended_private_key_type &p1, const fc::ecc::extended_public_key &p2)
 
bool operator== (const extended_private_key_type &p1, const extended_private_key_type &p2)
 
bool operator!= (const extended_private_key_type &p1, const extended_private_key_type &p2)
 
int string_to_int (fc::string input)
 
fc::string int_to_string (int input)
 

Typedef Documentation

◆ account_authority_map

Definition at line 8 of file authority.hpp.

◆ account_name_type

typedef fc::fixed_string_16 scorum::protocol::account_name_type

Definition at line 62 of file types.hpp.

◆ asset_symbol_type

using scorum::protocol::asset_symbol_type = typedef uint64_t

Definition at line 13 of file asset.hpp.

◆ authority_getter

typedef std::function<authority(const std::string&)> scorum::protocol::authority_getter

Definition at line 9 of file sign_state.hpp.

◆ authority_weight_type

Definition at line 68 of file types.hpp.

◆ block_header_extensions

Definition at line 78 of file base.hpp.

◆ block_header_extensions_type

Definition at line 82 of file base.hpp.

◆ block_id_type

typedef fc::ripemd160 scorum::protocol::block_id_type

Definition at line 63 of file types.hpp.

◆ chain_id_type

typedef fc::sha256 scorum::protocol::chain_id_type

Definition at line 61 of file types.hpp.

◆ checksum_type

typedef fc::ripemd160 scorum::protocol::checksum_type

Definition at line 64 of file types.hpp.

◆ comment_options_extension

Definition at line 36 of file comment.hpp.

◆ comment_options_extensions_type

Definition at line 38 of file comment.hpp.

◆ correct_score

using scorum::protocol::correct_score = typedef score_yes_no_market<market_kind::correct_score>

Definition at line 72 of file market.hpp.

◆ correct_score_away

Definition at line 71 of file market.hpp.

◆ correct_score_draw

Definition at line 70 of file market.hpp.

◆ correct_score_home

Definition at line 69 of file market.hpp.

◆ development_committee_change_banner_budgets_auction_properties_operation

Definition at line 219 of file proposal_operations.hpp.

◆ development_committee_change_post_budgets_auction_properties_operation

Definition at line 216 of file proposal_operations.hpp.

◆ digest_type

typedef fc::sha256 scorum::protocol::digest_type

Definition at line 66 of file types.hpp.

◆ extensions_type

Definition at line 83 of file base.hpp.

◆ future_extensions

Definition at line 80 of file base.hpp.

◆ game_type

using scorum::protocol::game_type = typedef fc::static_variant<soccer_game, hockey_game>

Definition at line 14 of file game.hpp.

◆ goal_away

Definition at line 76 of file market.hpp.

◆ goal_both

Definition at line 75 of file market.hpp.

◆ goal_home

Definition at line 74 of file market.hpp.

◆ handicap

using scorum::protocol::handicap = typedef over_under_market<market_kind::handicap>

Definition at line 67 of file market.hpp.

◆ int128_t

typedef boost::multiprecision::int128_t scorum::protocol::int128_t

Definition at line 17 of file asset.cpp.

◆ market_type

Definition at line 83 of file market.hpp.

◆ odds_fraction_type

Definition at line 11 of file odds.hpp.

◆ odds_value_type

using scorum::protocol::odds_value_type = typedef int32_t

Definition at line 10 of file odds.hpp.

◆ operation

using scorum::protocol::operation = typedef fc::static_variant<vote_operation, comment_operation, transfer_operation, transfer_to_scorumpower_operation, withdraw_scorumpower_operation, account_create_by_committee_operation, account_create_operation, account_create_with_delegation_operation, account_update_operation, witness_update_operation, account_witness_vote_operation, account_witness_proxy_operation, delete_comment_operation, comment_options_operation, set_withdraw_scorumpower_route_to_account_operation, set_withdraw_scorumpower_route_to_dev_pool_operation, prove_authority_operation, request_account_recovery_operation, recover_account_operation, change_recovery_account_operation, escrow_approve_operation, escrow_dispute_operation, escrow_release_operation, escrow_transfer_operation, decline_voting_rights_operation, delegate_scorumpower_operation, create_budget_operation, close_budget_operation, proposal_vote_operation, proposal_create_operation, atomicswap_initiate_operation, atomicswap_redeem_operation, atomicswap_refund_operation, close_budget_by_advertising_moderator_operation, update_budget_operation, create_game_operation, cancel_game_operation, update_game_markets_operation, update_game_start_time_operation, post_game_results_operation, post_bet_operation, cancel_pending_bets_operation, delegate_sp_from_reg_pool_operation, create_nft_operation, update_nft_meta_operation, create_game_round_operation, update_game_round_result_operation, adjust_nft_experience_operation, update_nft_name_operation, author_reward_operation, comment_benefficiary_reward_operation, comment_payout_update_operation, comment_reward_operation, curation_reward_operation, hardfork_operation, producer_reward_operation, active_sp_holders_reward_operation, return_scorumpower_delegation_operation, shutdown_witness_operation, witness_miss_block_operation, expired_contract_refund_operation, acc_finished_vesting_withdraw_operation, devpool_finished_vesting_withdraw_operation, acc_to_acc_vesting_withdraw_operation, devpool_to_acc_vesting_withdraw_operation, acc_to_devpool_vesting_withdraw_operation, devpool_to_devpool_vesting_withdraw_operation, proposal_virtual_operation, budget_outgo_operation, budget_owner_income_operation, active_sp_holders_reward_legacy_operation, budget_closing_operation, bets_matched_operation, game_status_changed_operation, bet_resolved_operation, bet_cancelled_operation, bet_restored_operation, bet_updated_operation >

NOTE: do not change the order of any operations prior to the virtual operations or it will trigger a hardfork.

Definition at line 13 of file operations.hpp.

◆ percent_type

Definition at line 69 of file types.hpp.

◆ private_key_type

typedef fc::ecc::private_key scorum::protocol::private_key_type

Definition at line 60 of file types.hpp.

◆ proposal_operation

Definition at line 233 of file proposal_operations.hpp.

◆ result_away

Definition at line 63 of file market.hpp.

◆ result_draw

Definition at line 62 of file market.hpp.

◆ result_home

Definition at line 61 of file market.hpp.

◆ round_home

Definition at line 65 of file market.hpp.

◆ share_type

Definition at line 73 of file types.hpp.

◆ share_value_type

using scorum::protocol::share_value_type = typedef int64_t

Definition at line 72 of file types.hpp.

◆ signature_type

typedef fc::ecc::compact_signature scorum::protocol::signature_type

Definition at line 67 of file types.hpp.

◆ total

using scorum::protocol::total = typedef over_under_market<market_kind::total>

Definition at line 78 of file market.hpp.

◆ total_goals_away

Definition at line 81 of file market.hpp.

◆ total_goals_home

Definition at line 80 of file market.hpp.

◆ transaction_id_type

Definition at line 65 of file types.hpp.

◆ vote_weight_type

Definition at line 70 of file types.hpp.

◆ wincase_type

Definition at line 99 of file market.hpp.

Enumeration Type Documentation

◆ bet_kind

enum scorum::protocol::bet_kind : uint8_t
strong
Enumerator
pending 
matched 

Definition at line 472 of file scorum_virtual_operations.hpp.

◆ bet_resolve_kind

enum scorum::protocol::bet_resolve_kind : uint8_t
strong
Enumerator
win 
draw 

Definition at line 442 of file scorum_virtual_operations.hpp.

◆ budget_type

Enumerator
post 
banner 

Definition at line 158 of file types.hpp.

◆ curve_id

Enumerator
quadratic 
linear 
square_root 
power1dot5 

Definition at line 150 of file types.hpp.

◆ game_status

enum scorum::protocol::game_status : uint8_t
strong
Enumerator
created 
started 
finished 
resolved 
expired 
cancelled 

Definition at line 6 of file game_status.hpp.

◆ market_kind

enum scorum::protocol::market_kind : uint16_t
strong
Enumerator
result 
round 
handicap 
correct_score 
goal 
total 
total_goals 

Definition at line 6 of file market_kind.hpp.

◆ quorum_type

Enumerator
none_quorum 
add_member_quorum 
exclude_member_quorum 
base_quorum 
transfer_quorum 
advertising_moderator_quorum 
budgets_auction_properties_quorum 
betting_moderator_quorum 
betting_resolve_delay_quorum 

Definition at line 13 of file proposal_operations.hpp.

Function Documentation

◆ add_authority_accounts()

template<typename AuthorityType >
void scorum::protocol::add_authority_accounts ( flat_set< account_name_type > &  result,
const AuthorityType &  a 
)

Definition at line 60 of file authority.hpp.

◆ create_market()

market_type scorum::protocol::create_market ( const wincase_type wincase)

Definition at line 56 of file market.cpp.

◆ create_opposite()

wincase_type scorum::protocol::create_opposite ( const wincase_type wincase)

Definition at line 61 of file market.cpp.

◆ create_wincases()

std::pair< wincase_type, wincase_type > scorum::protocol::create_wincases ( const market_type market)

Definition at line 51 of file market.cpp.

◆ FC_DECLARE_DERIVED_EXCEPTION() [1/3]

missing required owner authority missing required other authority scorum::protocol::FC_DECLARE_DERIVED_EXCEPTION ( tx_irrelevant_sig  ,
scorum::protocol::transaction_exception  ,
3050000  ,
"irrelevant signature included"   
)

◆ FC_DECLARE_DERIVED_EXCEPTION() [2/3]

scorum::protocol::FC_DECLARE_DERIVED_EXCEPTION ( tx_missing_active_auth  ,
scorum::protocol::transaction_exception  ,
3010000  ,
"missing required active authority  
)

◆ FC_DECLARE_DERIVED_EXCEPTION() [3/3]

missing required owner authority scorum::protocol::FC_DECLARE_DERIVED_EXCEPTION ( tx_missing_posting_auth  ,
scorum::protocol::transaction_exception  ,
3030000  ,
"missing required posting authority  
)

◆ game_markets()

const bf::map<bf::pair<soccer_game, std::set<market_kind> >, bf::pair<hockey_game, std::set<market_kind> > > scorum::protocol::game_markets ( bf::make_pair< soccer_game std::set< market_kind >{ market_kind::result, market_kind::round, market_kind::handicap, market_kind::correct_score, market_kind::goal, market_kind::total, market_kind::total_goals },
bf::make_pair< hockey_game std::set< market_kind >{ market_kind::result, market_kind::goal } 
)

◆ get_config()

fc::variant_object scorum::protocol::get_config ( )

Definition at line 12 of file get_config.cpp.

◆ get_market_kind()

market_kind scorum::protocol::get_market_kind ( const wincase_type wincase)

Definition at line 78 of file market.cpp.

◆ get_markets_kind()

template<typename T >
std::set<market_kind> scorum::protocol::get_markets_kind ( const T &  markets)

Definition at line 138 of file market.hpp.

◆ has_trd_state()

bool scorum::protocol::has_trd_state ( const market_type market)

Definition at line 66 of file market.cpp.

◆ int_to_string()

fc::string scorum::protocol::int_to_string ( int  input)
inline

Definition at line 21 of file version.cpp.

◆ is_asset_type()

bool scorum::protocol::is_asset_type ( asset  asset,
asset_symbol_type  symbol 
)
inline

Definition at line 14 of file scorum_operations.cpp.

◆ is_belong_markets()

template<typename T >
bool scorum::protocol::is_belong_markets ( const wincase_type wincase,
const T &  markets 
)

Definition at line 148 of file market.hpp.

◆ is_market_operation()

bool scorum::protocol::is_market_operation ( const operation op)

Definition at line 26 of file operations.cpp.

◆ is_unique()

template<class T >
bool scorum::protocol::is_unique ( const std::vector< T > &  input)

Definition at line 19 of file scorum_operations.cpp.

◆ is_valid_account_name()

bool scorum::protocol::is_valid_account_name ( const std::string &  name)

Names must comply with the following grammar (RFC 1035): <domain> ::= <subdomain> | " " <subdomain> ::= <label> | <subdomain> "." <label> <label> ::= <letter> [ [ <ldh-str> ] <let-dig> ] <ldh-str> ::= <let-dig-hyp> | <let-dig-hyp> <ldh-str> <let-dig-hyp> ::= <let-dig> | "-" <let-dig> ::= <letter> | <digit>

Which is equivalent to the following:

<domain> ::= <subdomain> | " " <subdomain> ::= <label> ("." <label>)* <label> ::= <letter> [ [ <let-dig-hyp>+ ] <let-dig> ] <let-dig-hyp> ::= <let-dig> | "-" <let-dig> ::= <letter> | <digit>

I.e. a valid name consists of a dot-separated sequence of one or more labels consisting of the following rules:

  • Each label is three characters or more
  • Each label begins with a letter
  • Each label ends with a letter or digit
  • Each label contains only letters, digits or hyphens

In addition we require the following:

  • All letters are lowercase
  • Length is between (inclusive) SCORUM_MIN_ACCOUNT_NAME_LENGTH and SCORUM_MAX_ACCOUNT_NAME_LENGTH

Definition at line 58 of file authority.cpp.

◆ is_virtual_operation()

bool scorum::protocol::is_virtual_operation ( const operation op)

Definition at line 41 of file operations.cpp.

◆ match_wincases()

bool scorum::protocol::match_wincases ( const wincase_type lhs,
const wincase_type rhs 
)

Definition at line 71 of file market.cpp.

◆ operation_get_required_quorum()

percent_type scorum::protocol::operation_get_required_quorum ( committee committee_service,
const proposal_operation op 
)

Definition at line 168 of file proposal_operations.cpp.

◆ operation_validate()

void scorum::protocol::operation_validate ( const proposal_operation op)

Definition at line 163 of file proposal_operations.cpp.

◆ operator!=() [1/3]

bool scorum::protocol::operator!= ( const extended_private_key_type p1,
const extended_private_key_type p2 
)

Definition at line 178 of file types.cpp.

◆ operator!=() [2/3]

bool scorum::protocol::operator!= ( const extended_public_key_type p1,
const extended_public_key_type p2 
)

Definition at line 123 of file types.cpp.

◆ operator!=() [3/3]

bool scorum::protocol::operator!= ( const public_key_type p1,
const public_key_type p2 
)

Definition at line 68 of file types.cpp.

◆ operator<() [1/6]

template<market_kind kind, typename tag >
bool scorum::protocol::operator< ( const over_under_market< kind, tag > &  lhs,
const over_under_market< kind, tag > &  rhs 
)

Definition at line 7 of file market_comparison.hpp.

◆ operator<() [2/6]

template<bool side, market_kind kind, typename tag >
bool scorum::protocol::operator< ( const over_under_wincase< side, kind, tag > &  lhs,
const over_under_wincase< side, kind, tag > &  rhs 
)

Definition at line 7 of file wincase_comparison.hpp.

◆ operator<() [3/6]

template<market_kind kind, typename tag >
bool scorum::protocol::operator< ( const score_yes_no_market< kind, tag > &  lhs,
const score_yes_no_market< kind, tag > &  rhs 
)

Definition at line 19 of file market_comparison.hpp.

◆ operator<() [4/6]

template<bool side, market_kind kind, typename tag >
bool scorum::protocol::operator< ( const score_yes_no_wincase< side, kind, tag > &  lhs,
const score_yes_no_wincase< side, kind, tag > &  rhs 
)

Definition at line 19 of file wincase_comparison.hpp.

◆ operator<() [5/6]

template<market_kind kind, typename tag >
bool scorum::protocol::operator< ( const yes_no_market< kind, tag > &  lhs,
const yes_no_market< kind, tag > &  rhs 
)

Definition at line 13 of file market_comparison.hpp.

◆ operator<() [6/6]

template<bool side, market_kind kind, typename tag >
bool scorum::protocol::operator< ( const yes_no_wincase< side, kind, tag > &  lhs,
const yes_no_wincase< side, kind, tag > &  rhs 
)

Definition at line 13 of file wincase_comparison.hpp.

◆ operator<<() [1/2]

template<typename Stream >
Stream& scorum::protocol::operator<< ( Stream &  stream,
const scorum::protocol::asset a 
)

Definition at line 196 of file asset.hpp.

◆ operator<<() [2/2]

template<typename Stream >
Stream& scorum::protocol::operator<< ( Stream &  stream,
const scorum::protocol::odds o 
)

Definition at line 73 of file odds.hpp.

◆ operator==() [1/7]

bool scorum::protocol::operator== ( const authority a,
const authority b 
)

Definition at line 98 of file authority.cpp.

◆ operator==() [2/7]

bool scorum::protocol::operator== ( const extended_private_key_type p1,
const extended_private_key_type p2 
)

Definition at line 173 of file types.cpp.

◆ operator==() [3/7]

bool scorum::protocol::operator== ( const extended_private_key_type p1,
const fc::ecc::extended_public_key &  p2 
)

Definition at line 168 of file types.cpp.

◆ operator==() [4/7]

bool scorum::protocol::operator== ( const extended_public_key_type p1,
const extended_public_key_type p2 
)

Definition at line 118 of file types.cpp.

◆ operator==() [5/7]

bool scorum::protocol::operator== ( const extended_public_key_type p1,
const fc::ecc::extended_public_key &  p2 
)

Definition at line 113 of file types.cpp.

◆ operator==() [6/7]

bool scorum::protocol::operator== ( const public_key_type p1,
const fc::ecc::public_key &  p2 
)

Definition at line 58 of file types.cpp.

◆ operator==() [7/7]

bool scorum::protocol::operator== ( const public_key_type p1,
const public_key_type p2 
)

Definition at line 63 of file types.cpp.

◆ operator>>() [1/2]

template<typename Stream >
Stream& scorum::protocol::operator>> ( Stream &  stream,
scorum::protocol::asset a 
)

Definition at line 202 of file asset.hpp.

◆ operator>>() [2/2]

template<typename Stream >
Stream& scorum::protocol::operator>> ( Stream &  stream,
scorum::protocol::odds o 
)

Definition at line 79 of file odds.hpp.

◆ string_to_int()

int scorum::protocol::string_to_int ( fc::string  input)
inline

Definition at line 13 of file version.cpp.

◆ validate_account_name()

void scorum::protocol::validate_account_name ( const std::string &  name)
inline

Definition at line 15 of file base.hpp.

◆ validate_bet_ids()

void scorum::protocol::validate_bet_ids ( const fc::flat_set< int64_t > &  bet_ids)

Definition at line 91 of file invariants_validation.cpp.

◆ validate_game()

void scorum::protocol::validate_game ( const game_type game,
const fc::flat_set< market_type > &  markets 
)

Definition at line 31 of file invariants_validation.cpp.

◆ validate_if_wincase_in_game()

void scorum::protocol::validate_if_wincase_in_game ( const game_type game,
const wincase_type wincase 
)

Definition at line 81 of file invariants_validation.cpp.

◆ validate_json_metadata()

void scorum::protocol::validate_json_metadata ( const std::string &  json_metadata)
inline

Definition at line 26 of file base.hpp.

◆ validate_market()

void scorum::protocol::validate_market ( const market_type market)

Definition at line 100 of file invariants_validation.cpp.

◆ validate_markets()

void scorum::protocol::validate_markets ( const fc::flat_set< market_type > &  markets)

Definition at line 47 of file invariants_validation.cpp.

◆ validate_permlink()

void scorum::protocol::validate_permlink ( const std::string &  permlink)
inline

Definition at line 20 of file base.hpp.

◆ validate_quorum()

void scorum::protocol::validate_quorum ( quorum_type  t,
protocol::percent_type  quorum 
)
inline

Definition at line 26 of file proposal_operations.hpp.

◆ validate_wincase()

void scorum::protocol::validate_wincase ( const wincase_type wincase)

Definition at line 63 of file invariants_validation.cpp.

◆ validate_wincases()

void scorum::protocol::validate_wincases ( const fc::flat_set< wincase_type > &  wincases)

Definition at line 55 of file invariants_validation.cpp.

◆ verify_authority()

void scorum::protocol::verify_authority ( const std::vector< operation > &  ops,
const flat_set< public_key_type > &  sigs,
const authority_getter get_active,
const authority_getter get_owner,
const authority_getter get_posting,
uint32_t  max_recursion = SCORUM_MAX_SIG_CHECK_DEPTH,
bool  allow_committe = false,
const flat_set< account_name_type > &  active_aprovals = flat_set<account_name_type>(),
const flat_set< account_name_type > &  owner_aprovals = flat_set<account_name_type>(),
const flat_set< account_name_type > &  posting_approvals = flat_set<account_name_type>() 
)

Transactions with operations required posting authority cannot be combined with transactions requiring active or owner authority. This is for ease of implementation. Future versions of authority verification may be able to check for the merged authority of active and posting.

Transactions with operations required posting authority cannot be combined with transactions requiring active or owner authority. This is for ease of implementation. Future versions of authority verification may be able to check for the merged authority of active and posting.

Definition at line 88 of file transaction.cpp.