BitShares-Core
7.0.2
BitShares blockchain node software and command-line wallet software
|
Go to the documentation of this file.
27 #include <graphene/chain/hardfork.hpp>
35 namespace graphene {
namespace chain {
39 return *_p_core_asset_obj;
44 return *_p_core_dynamic_data_obj;
49 return *_p_global_prop_obj;
54 return *_p_chain_property_obj;
59 return *_p_dyn_global_prop_obj;
94 return _node_property_object;
99 return _node_property_object;
103 account_id_type account,
const operation &op,
106 const auto&
index = get_index_type<custom_authority_index>().indices().
get<by_account_custom>();
110 vector<std::reference_wrapper<const custom_authority_object>> valid_auths;
111 std::copy_if(range.first, range.second, std::back_inserter(valid_auths), is_valid);
113 vector<authority> results;
114 for (
const auto& cust_auth : valid_auths) {
116 auto result = cust_auth.get().get_predicate()(op);
118 results.emplace_back(cust_auth.get().auth);
119 else if (rejected_authorities !=
nullptr)
120 rejected_authorities->insert(std::make_pair(cust_auth.get().get_id(), std::move(result)));
122 if (rejected_authorities !=
nullptr)
123 rejected_authorities->insert(std::make_pair(cust_auth.get().get_id(), std::move(e)));
144 return account_statistics_id_type(owner.instance)(*this);
149 return *_p_witness_schedule_obj;
154 const auto& limit_index = get_index_type<limit_order_index>().indices().get<by_is_settled_debt>();
155 auto itr = limit_index.lower_bound( std::make_tuple(
true, a ) );
156 if( itr != limit_index.end() && itr->receive_asset_id() == a )
162 bool force_by_collateral_index )
const
164 bool find_by_collateral =
true;
165 if( !force_by_collateral_index )
173 if( !find_by_collateral )
175 const auto& call_price_index = get_index_type<call_order_index>().indices().get<by_price>();
176 auto call_itr = call_price_index.lower_bound( call_min );
177 if( call_itr != call_price_index.end() )
178 call_ptr = &(*call_itr);
183 const auto& call_collateral_index = get_index_type<call_order_index>().indices().get<by_collateral>();
184 auto call_itr = call_collateral_index.lower_bound( call_min );
185 if( call_itr != call_collateral_index.end() )
186 call_ptr = &(*call_itr);
Maintains global state information (committee_member list, current fees)
const limit_order_object * find_settled_debt_order(const asset_id_type &a) const
const chain_id_type & get_chain_id() const
map< custom_authority_id_type, rejected_predicate > rejected_predicate_map
Used to generate a useful error report when an exception is thrown.
time_point_sec head_block_time() const
contains all of the parameters necessary to calculate the fee for any operation
time_point_sec next_maintenance_time
fc::static_variant< transfer_operation, limit_order_create_operation, limit_order_cancel_operation, call_order_update_operation, fill_order_operation, account_create_operation, account_update_operation, account_whitelist_operation, account_upgrade_operation, account_transfer_operation, asset_create_operation, asset_update_operation, asset_update_bitasset_operation, asset_update_feed_producers_operation, asset_issue_operation, asset_reserve_operation, asset_fund_fee_pool_operation, asset_settle_operation, asset_global_settle_operation, asset_publish_feed_operation, witness_create_operation, witness_update_operation, proposal_create_operation, proposal_update_operation, proposal_delete_operation, withdraw_permission_create_operation, withdraw_permission_update_operation, withdraw_permission_claim_operation, withdraw_permission_delete_operation, committee_member_create_operation, committee_member_update_operation, committee_member_update_global_parameters_operation, vesting_balance_create_operation, vesting_balance_withdraw_operation, worker_create_operation, custom_operation, assert_operation, balance_claim_operation, override_transfer_operation, transfer_to_blind_operation, blind_transfer_operation, transfer_from_blind_operation, asset_settle_cancel_operation, asset_claim_fees_operation, fba_distribute_operation, bid_collateral_operation, execute_bid_operation, asset_claim_pool_operation, asset_update_issuer_operation, htlc_create_operation, htlc_redeem_operation, htlc_redeemed_operation, htlc_extend_operation, htlc_refund_operation, custom_authority_create_operation, custom_authority_update_operation, custom_authority_delete_operation, ticket_create_operation, ticket_update_operation, liquidity_pool_create_operation, liquidity_pool_delete_operation, liquidity_pool_deposit_operation, liquidity_pool_withdraw_operation, liquidity_pool_exchange_operation, samet_fund_create_operation, samet_fund_delete_operation, samet_fund_update_operation, samet_fund_borrow_operation, samet_fund_repay_operation, credit_offer_create_operation, credit_offer_delete_operation, credit_offer_update_operation, credit_offer_accept_operation, credit_deal_repay_operation, credit_deal_expired_operation, liquidity_pool_update_operation, credit_deal_update_operation, limit_order_update_operation >
chain_parameters parameters
vector< authority > get_viable_custom_authorities(account_id_type account, const operation &op, rejected_predicate_map *rejected_authorities=nullptr) const
Get a list of custom authorities which can validate the provided operation for the provided account.
block_id_type head_block_id
tracks the parameters of an asset
Tracks account custom authorities.
const asset_object & get_core_asset() const
const fee_schedule & get_current_fees() const
asset_id_type debt_type() const
block_id_type head_block_id() const
const node_property_object & get_node_properties() const
uint32_t head_block_number
const object & get(object_id_type id) const
const fee_schedule & current_fee_schedule() const
tracks the asset information that changes frequently
const asset_dynamic_data_object & get_core_dynamic_data() const
uint32_t active_sessions() const
Contains per-node database configuration.
contains properties that only apply to bitassets (market issued assets)
const chain_property_object & get_chain_properties() const
uint32_t head_block_num() const
uint32_t last_non_undoable_block_num() const
node_property_object & node_properties()
Maintains global state information (committee_member list, current fees)
tracks debt and call price information
const witness_schedule_object & get_witness_schedule_object() const
const account_statistics_object & get_account_stats_by_owner(account_id_type owner) const
const global_property_object & get_global_properties() const
const dynamic_global_property_object & get_dynamic_global_properties() const
const call_order_object * find_least_collateralized_short(const asset_bitasset_data_object &bitasset, bool force_by_collateral_index) const
abstract base class for accessing objects indexed in various ways.
an offer to sell an amount of an asset at a specified exchange rate by a certain time
asset_id_type short_backing_asset
bitasset_options options
The tunable options for BitAssets are stored in this field.
uint8_t block_interval
interval in seconds between blocks
asset_id_type asset_id
The asset this object belong to.