BitShares-Core  4.0.0
BitShares blockchain implementation and command-line interface software
Classes | Typedefs | Enumerations | Functions | Variables
graphene::protocol Namespace Reference

Classes

struct  account_create_operation
 
struct  account_name_eq_lit_predicate
 
struct  account_options
 These are the fields which can be updated by the active authority. More...
 
struct  account_transfer_operation
 transfers the account to another account while clearing the white listIn theory an account can be transferred by simply updating the authorities, but that kind of transfer lacks semantic meaning and is more often done to rotate keys without transferring ownership. This operation is used to indicate the legal transfer of title to this account and a break in the operation history. More...
 
struct  account_update_operation
 Update an existing account. More...
 
struct  account_upgrade_operation
 Manage an account's membership statusThis operation is used to upgrade an account to a member, or renew its subscription. If an account which is an unexpired annual subscription member publishes this operation with upgrade_to_lifetime_member set to false, the account's membership expiration date will be pushed backward one year. If a basic account publishes it with upgrade_to_lifetime_member set to false, the account will be upgraded to a subscription member with an expiration date one year after the processing time of this operation. More...
 
struct  account_whitelist_operation
 This operation is used to whitelist and blacklist accounts, primarily for transacting in whitelisted assetsAccounts can freely specify opinions about other accounts, in the form of either whitelisting or blacklisting them. This information is used in chain validation only to determine whether an account is authorized to transact in an asset type which enforces a whitelist, but third parties can use this information for other uses as well, as long as it does not conflict with the use of whitelisted assets. More...
 
struct  adder
 
struct  additional_asset_options
 
class  address
 a 160 bit hash of a public key More...
 
struct  assert_operation
 assert that some conditions are true.This operation performs no changes to the database state, but can but used to verify pre or post conditions for other operations. More...
 
struct  asset
 
struct  asset_claim_fees_operation
 used to transfer accumulated fees back to the issuer's balance. More...
 
struct  asset_claim_pool_operation
 Transfers BTS from the fee pool of a specified asset back to the issuer's balance. More...
 
struct  asset_create_operation
 
struct  asset_fund_fee_pool_operation
 
struct  asset_global_settle_operation
 allows global settling of bitassets (black swan or prediction markets) More...
 
struct  asset_issue_operation
 
struct  asset_options
 The asset_options struct contains options available on all assets in the network. More...
 
struct  asset_publish_feed_operation
 Publish price feeds for market-issued assetsPrice feed providers use this operation to publish their price feeds for market-issued assets. A price feed is used to tune the market for a particular market-issued asset. For each value in the feed, the median across all committee_member feeds for that asset is calculated and the market for the asset is configured with the median of that value. More...
 
struct  asset_reserve_operation
 used to take an asset out of circulation, returning to the issuer More...
 
struct  asset_settle_cancel_operation
 
struct  asset_settle_operation
 Schedules a market-issued asset for automatic settlementHolders of market-issued assests may request a forced settlement for some amount of their asset. This means that the specified sum will be locked by the chain and held for the settlement period, after which time the chain will choose a margin posision holder and buy the settled asset using the margin's collateral. The price of this sale will be based on the feed price for the market-issued asset being settled. The exact settlement price will be the feed price at the time of settlement with an offset in favor of the margin position, where the offset is a blockchain parameter set in the global_property_object. More...
 
struct  asset_symbol_eq_lit_predicate
 
struct  asset_update_bitasset_operation
 Update options specific to BitAssetsBitAssets have some options which are not relevant to other asset types. This operation is used to update those options an an existing BitAsset. More...
 
struct  asset_update_feed_producers_operation
 Update the set of feed-producing accounts for a BitAssetBitAssets have price feeds selected by taking the median values of recommendations from a set of feed producers. This operation is used to specify which accounts may produce feeds for a given BitAsset. More...
 
struct  asset_update_issuer_operation
 Update issuer of an assetAn issuer has general administrative power of an asset and in some cases also its shares issued to individuals. Thus, changing the issuer today requires the use of a separate operation that needs to be signed by the owner authority. More...
 
struct  asset_update_operation
 Update options common to all assetsThere are a number of options which all assets in the network use. These options are enumerated in the asset_options struct. This operation is used to update these options for an existing asset. More...
 
struct  attribute_assertion
 
struct  attribute_assertion< extension< Extension > >
 
struct  attribute_assertion< fc::optional< Field > >
 
class  authority
 Identifies a weighted set of keys and accounts that must approve operations. More...
 
struct  balance_claim_operation
 Claim a balance in a balance_object. More...
 
struct  base_operation
 
struct  bid_collateral_operation
 
struct  bitasset_options
 The bitasset_options struct contains configurable options available only to BitAssets. More...
 
struct  blind_input
 
struct  blind_memo
 
class  blind_output
 Defines data required to create a new blind commitmentThe blinded output that must be proven to be greater than 0. More...
 
struct  blind_transfer_operation
 Transfers from blind to blind. More...
 
class  block_header
 
struct  block_id_predicate
 
struct  burn_worker_initializer
 
struct  buyback_account_options
 
struct  calc_fee_visitor
 
struct  call_order_update_operation
 
struct  cdd_vesting_policy_initializer
 
struct  chain_parameters
 
struct  committee_member_create_operation
 Create a committee_member object, as a bid to hold a committee_member seat on the network.Accounts which wish to become committee_members may use this operation to create a committee_member object which stakeholders may vote on to approve its position as a committee_member. More...
 
struct  committee_member_update_global_parameters_operation
 Used by committee_members to update the global parameters of the blockchain.This operation allows the committee_members to update the global parameters on the blockchain. These control various tunable aspects of the chain, including block and maintenance intervals, maximum data sizes, the fees charged by the network, etc. More...
 
struct  committee_member_update_operation
 Update a committee_member object.Currently the only field which can be updated is the url field. More...
 
struct  custom_authority_create_operation
 Create a new custom authority. More...
 
struct  custom_authority_delete_operation
 Delete a custom authority. More...
 
struct  custom_authority_options_type
 
struct  custom_authority_update_operation
 Update a custom authority. More...
 
struct  custom_operation
 provides a generic way to add higher level protocols on top of witness consensusThere is no validation for this operation other than that required auths are valid and a fee is paid that is appropriate for the data contained. More...
 
struct  execute_bid_operation
 
struct  extension
 
struct  fba_distribute_operation
 
class  fee_helper
 
class  fee_helper< account_create_operation >
 
class  fee_helper< asset_claim_pool_operation >
 
class  fee_helper< asset_update_issuer_operation >
 
class  fee_helper< bid_collateral_operation >
 
class  fee_helper< htlc_create_operation >
 
class  fee_helper< htlc_extend_operation >
 
class  fee_helper< htlc_redeem_operation >
 
class  fee_helper< ticket_create_operation >
 
class  fee_helper< ticket_update_operation >
 
struct  fee_schedule
 contains all of the parameters necessary to calculate the fee for any operation More...
 
struct  fill_order_operation
 
struct  generic_operation_result
 
struct  graphene_extension_pack_count_visitor
 
struct  graphene_extension_pack_read_visitor
 
struct  graphene_extension_unpack_visitor
 
struct  htlc_create_operation
 
struct  htlc_extend_operation
 
struct  htlc_options
 
struct  htlc_redeem_operation
 
struct  htlc_redeemed_operation
 
struct  htlc_refund_operation
 
struct  instant_vesting_policy_initializer
 
struct  is_container_impl
 
struct  is_container_impl< T, make_void< typename T::value_type, decltype(declval< T >().size())>
 
struct  is_flat_set_impl
 
struct  is_flat_set_impl< flat_set< T > >
 
struct  limit_order_cancel_operation
 
class  limit_order_create_operation
 instructs the blockchain to attempt to sell one asset for anotherThe blockchain will atempt to sell amount_to_sell.asset_id for as much min_to_receive.asset_id as possible. The fee will be paid by the seller's account. Market fees will apply as specified by the issuer of both the selling asset and the receiving asset as a percentage of the amount exchanged. More...
 
struct  linear_vesting_policy_initializer
 
struct  make_flat_set
 
struct  memo_data
 defines the keys used to derive the shared secret More...
 
struct  memo_message
 defines a message and checksum to enable validation of successful decryption More...
 
struct  no_special_authority
 
struct  op_wrapper
 necessary to support nested operations inside the proposal_create_operation More...
 
struct  operation_get_required_auth
 
struct  operation_validator
 Used to validate operations in a polymorphic manner. More...
 
class  override_transfer_operation
 Allows the issuer of an asset to transfer an asset from any account to any account if they have override_authority. More...
 
struct  p10
 
struct  p10< 0 >
 
class  precomputable_transaction
 
struct  predicate_compare
 
struct  predicate_compare< fc::optional< Field >, Argument, void >
 
struct  predicate_compare< Field, Argument, std::enable_if_t< is_integral< Field > &&is_integral< Argument > &&!std::is_same< Field, Argument >::value > >
 
struct  predicate_compare< Field, Argument, std::enable_if_t< std::is_same< Field, Argument >::value > >
 
struct  predicate_eq
 
struct  predicate_eq< fc::optional< Field >, Argument, std::enable_if_t< comparable_types< Field, Argument > > >
 
struct  predicate_eq< fc::optional< Field >, void_t, void >
 
struct  predicate_eq< Field, Argument, std::enable_if_t< is_container< Field > &&is_integral< Argument > > >
 
struct  predicate_eq< Field, Argument, std::enable_if_t< is_integral< Field > &&is_integral< Argument > &&!std::is_same< Field, Argument >::value > >
 
struct  predicate_eq< Field, Argument, std::enable_if_t< std::is_same< Field, Argument >::value > >
 
struct  predicate_ge
 
struct  predicate_gt
 
struct  predicate_has_all
 
struct  predicate_has_all< fc::optional< OptionalType >, Argument, void >
 
struct  predicate_has_all< FieldContainer, flat_set< ArgumentElement >, std::enable_if_t< is_container< FieldContainer > &&!is_flat_set< FieldContainer > &&comparable_types< typename FieldContainer::value_type, ArgumentElement > > >
 
struct  predicate_has_all< flat_set< FieldElement >, flat_set< ArgumentElement >, std::enable_if_t< comparable_types< FieldElement, ArgumentElement > > >
 
struct  predicate_has_none
 
struct  predicate_has_none< fc::optional< OptionalType >, Argument, void >
 
struct  predicate_has_none< FieldContainer, flat_set< ArgumentElement >, std::enable_if_t< is_container< FieldContainer > &&!is_flat_set< FieldContainer > &&comparable_types< typename FieldContainer::value_type, ArgumentElement > > >
 
struct  predicate_has_none< flat_set< FieldElement >, flat_set< ArgumentElement >, std::enable_if_t< comparable_types< FieldElement, ArgumentElement > > >
 
struct  predicate_in
 
struct  predicate_in< Container, flat_set< Element >, std::enable_if_t< is_container< Container > &&comparable_types< typename Container::value_type, Element > > >
 
struct  predicate_in< fc::optional< Field >, flat_set< Element >, std::enable_if_t< comparable_types< Field, Element > > >
 
struct  predicate_in< fc::safe< Field >, flat_set< Element >, std::enable_if_t< comparable_types< Field, Element > > >
 
struct  predicate_in< Field, flat_set< Element >, std::enable_if_t< comparable_types< Field, Element > &&!is_safe< Field > > >
 
struct  predicate_invalid
 
struct  predicate_le
 
struct  predicate_lt
 
struct  predicate_ne
 
struct  predicate_not_in
 
struct  predicate_not_in< Container, flat_set< Element >, std::enable_if_t< is_container< Container > &&comparable_types< typename Container::value_type, Element > > >
 
struct  predicate_result
 A type describing the result of a restriction predicate. More...
 
struct  predicate_validator
 
struct  price
 The price struct stores asset prices in the BitShares system. More...
 
class  price_feed
 defines market parameters for margin positions More...
 
struct  processed_transaction
 captures the result of evaluating the operations contained in the transaction More...
 
struct  proposal_create_operation
 The proposal_create_operation creates a transaction proposal, for use in multi-sig scenariosCreates a transaction proposal. The operations which compose the transaction are listed in order in proposed_ops, and expiration_time specifies the time by which the proposal must be accepted or it will fail permanently. The expiration_time cannot be farther in the future than the maximum expiration time set in the global properties object. More...
 
struct  proposal_delete_operation
 The proposal_delete_operation deletes an existing transaction proposalThis operation allows the early veto of a proposed transaction. It may be used by any account which is a required authority on the proposed transaction, when that account's holder feels the proposal is ill-advised and he decides he will never approve of it and wishes to put an end to all discussion of the issue. Because he is a required authority, he could simply refuse to add his approval, but this would leave the topic open for debate until the proposal expires. Using this operation, he can prevent any further breath from being wasted on such an absurd proposal. More...
 
struct  proposal_update_operation
 The proposal_update_operation updates an existing transaction proposalThis operation allows accounts to add or revoke approval of a proposed transaction. Signatures sufficient to satisfy the authority of each account in approvals are required on the transaction containing this operation. More...
 
struct  pts_address
 
class  pubkey_comparator
 
struct  public_key_type
 
struct  refund_worker_initializer
 
struct  restriction
 
struct  set_fee_visitor
 
struct  sign_state
 
class  signed_block
 
class  signed_block_header
 
class  signed_transaction
 adds a signature to a transaction More...
 
struct  special_authority_validate_visitor
 
struct  stealth_confirmation
 
struct  ticket_create_operation
 Creates a new ticket. More...
 
struct  ticket_update_operation
 Updates an existing ticket. More...
 
struct  top_holders_special_authority
 
class  transaction
 groups operations that should be applied atomically More...
 
struct  transfer_from_blind_operation
 Converts blinded/stealth balance to a public account balance. More...
 
struct  transfer_operation
 Transfers an amount of one asset from one account to another. More...
 
class  transfer_to_blind_operation
 Converts public account balance to a blinded or stealth balance. More...
 
struct  transform_to_fee_parameters
 
struct  transform_to_fee_parameters< fc::static_variant< T... > >
 
struct  variant_assertion
 
struct  variant_assertion< fc::optional< static_variant< Types... > > >
 
struct  variant_assertion< static_variant< Types... > >
 
struct  vesting_balance_create_operation
 Create a vesting balance.The chain allows a user to create a vesting balance. Normally, vesting balances are created automatically as part of cashback and worker operations. This operation allows vesting balances to be created manually as well. More...
 
struct  vesting_balance_withdraw_operation
 Withdraw from a vesting balance.Withdrawal from a not-completely-mature vesting balance will result in paying fees. More...
 
struct  vesting_balance_worker_initializer
 
struct  void_result
 
struct  void_t
 
struct  vote_id_type
 An ID for some votable object. More...
 
struct  withdraw_permission_claim_operation
 Withdraw from an account which has published a withdrawal permissionThis operation is used to withdraw from an account which has authorized such a withdrawal. It may be executed at most once per withdrawal period for the given permission. On execution, amount_to_withdraw is transferred from withdraw_from_account to withdraw_to_account, assuming amount_to_withdraw is within the withdrawal limit. The withdrawal permission will be updated to note that the withdrawal for the current period has occurred, and further withdrawals will not be permitted until the next withdrawal period, assuming the permission has not expired. This operation may be executed at any time within the current withdrawal period. More...
 
struct  withdraw_permission_create_operation
 Create a new withdrawal permissionThis operation creates a withdrawal permission, which allows some authorized account to withdraw from an authorizing account. This operation is primarily useful for scheduling recurring payments. More...
 
struct  withdraw_permission_delete_operation
 Delete an existing withdrawal permissionThis operation cancels a withdrawal permission, thus preventing any future withdrawals using that permission. More...
 
struct  withdraw_permission_update_operation
 Update an existing withdraw permissionThis oeration is used to update the settings for an existing withdrawal permission. The accounts to withdraw to and from may never be updated. The fields which may be updated are the withdrawal limit (both amount and asset type may be updated), the withdrawal period length, the remaining number of periods until expiration, and the starting time of the new period. More...
 
struct  witness_create_operation
 Create a witness object, as a bid to hold a witness position on the network.Accounts which wish to become witnesses may use this operation to create a witness object which stakeholders may vote on to approve its position as a witness. More...
 
struct  witness_update_operation
 Update a witness object's URL and block signing key. More...
 
struct  worker_create_operation
 Create a new worker object. More...
 
struct  zero_fee_visitor
 

Typedefs

using result_type = object_restriction_predicate< operation >
 
using restriction_function = restriction::function_type
 
using restriction_argument = restriction::argument_type
 
template<typename... >
using make_void = void
 
template<typename Field >
using object_restriction_predicate = std::function< predicate_result(const Field &)>
 
using comparable_types_list = typelist::list< int64_t, string, time_point_sec, account_id_type, asset_id_type, force_settlement_id_type, committee_member_id_type, witness_id_type, limit_order_id_type, call_order_id_type, custom_id_type, proposal_id_type, withdraw_permission_id_type, vesting_balance_id_type, worker_id_type, balance_id_type >
 
using list_types_list = typelist::transform< typelist::concat< typelist::list< bool, public_key_type, fc::sha256 >, comparable_types_list >, make_flat_set >
 
using equality_types_list = typename typelist::concat< typelist::list< void_t, bool, public_key_type, fc::sha256 >, comparable_types_list, list_types_list >
 
using attr_types_list = typelist::list< vector< restriction >>
 
using or_types_list = typelist::list< vector< vector< restriction >>>
 
using operation_list_1 = static_variant< typelist::slice< operation::list, 0, 4 >>
 
using operation_list_2 = static_variant< typelist::slice< operation::list, 5, 9 >>
 
using operation_list_3 = static_variant< typelist::slice< operation::list, 9, 11 >>
 
using operation_list_4 = static_variant< typelist::slice< operation::list, 11, 12 >>
 
using operation_list_5 = static_variant< typelist::slice< operation::list, 12, 15 >>
 
using operation_list_6 = static_variant< typelist::slice< operation::list, 15, 22 >>
 
using operation_list_7 = static_variant< typelist::slice< operation::list, 22, 29 >>
 
using operation_list_8 = static_variant< typelist::slice< operation::list, 29, 32 >>
 
using operation_list_9 = static_variant< typelist::slice< operation::list, 32, 35 >>
 
using operation_list_10 = static_variant< typelist::slice< operation::list, 35, 42 >>
 
using operation_list_11 = static_variant< typelist::builder<>::add< asset_claim_fees_operation >::add< bid_collateral_operation >::add_list< typelist::slice< operation::list, 47, 51 >>::add< htlc_extend_operation >::finalize >
 
using operation_list_12 = static_variant< typelist::slice< operation::list, 54 >>
 
using virtual_operations_list = static_variant< fill_order_operation, asset_settle_cancel_operation, fba_distribute_operation, execute_bid_operation, htlc_redeemed_operation, htlc_refund_operation >
 
typedef static_variant< account_name_eq_lit_predicate, asset_symbol_eq_lit_predicate, block_id_predicatepredicate
 
typedef extension< additional_asset_optionsadditional_asset_options_t
 
typedef fc::static_variant< void_result, object_id_type, asset, generic_operation_resultoperation_result
 
typedef static_variant< void_tfuture_extensions
 
using extensions_type = future_extensions::flat_set_type
 
using fee_parameters = transform_to_fee_parameters< operation >::type
 
typedef fee_schedule fee_schedule_type
 
typedef fc::ripemd160 htlc_algo_ripemd160
 
typedef fc::sha1 htlc_algo_sha1
 
typedef fc::sha256 htlc_algo_sha256
 
typedef fc::hash160 htlc_algo_hash160
 
typedef fc::static_variant< htlc_algo_ripemd160, htlc_algo_sha1, htlc_algo_sha256, htlc_algo_hash160htlc_hash
 
typedef 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_operationoperation
 
using restriction_predicate_function = std::function< predicate_result(const operation &)>
 A restriction predicate is a function accepting an operation and returning a predicate_result. More...
 
typedef static_variant< no_special_authority, top_holders_special_authorityspecial_authority
 
using rejected_predicate = static_variant< predicate_result, fc::exception >
 
using rejected_predicate_map = map< custom_authority_id_type, rejected_predicate >
 
using custom_authority_lookup = std::function< vector< authority >(account_id_type, const operation &, rejected_predicate_map *)>
 
using private_key_type = fc::ecc::private_key
 
using chain_id_type = fc::sha256
 
using ratio_type = boost::rational< int32_t >
 
using block_id_type = fc::ripemd160
 
using checksum_type = fc::ripemd160
 
using transaction_id_type = fc::ripemd160
 
using digest_type = fc::sha256
 
using signature_type = fc::ecc::compact_signature
 
using share_type = safe< int64_t >
 
using weight_type = uint16_t
 
typedef fc::static_variant< linear_vesting_policy_initializer, cdd_vesting_policy_initializer, instant_vesting_policy_initializervesting_policy_initializer
 
typedef static_variant< refund_worker_initializer, vesting_balance_worker_initializer, burn_worker_initializerworker_initializer
 

Enumerations

enum  ticket_type {
  liquid = 0, lock_180_days = 1, lock_360_days = 2, lock_720_days = 3,
  lock_forever = 4, TICKET_TYPE_COUNT = 5
}
 Type of a ticket. More...
 
enum  asset_issuer_permission_flags {
  charge_market_fee = 0x01, white_list = 0x02, override_authority = 0x04, transfer_restricted = 0x08,
  disable_force_settle = 0x10, global_settle = 0x20, disable_confidential = 0x40, witness_fed_asset = 0x80,
  committee_fed_asset = 0x100, lock_max_supply = 0x200, disable_new_supply = 0x400, disable_mcr_update = 0x800,
  disable_icr_update = 0x1000, disable_mssr_update = 0x2000
}
 
enum  reserved_spaces { relative_protocol_ids = 0, protocol_ids = 1, implementation_ids = 2 }
 

Functions

bool is_valid_name (const string &name)
 
bool is_cheap_name (const string &n)
 
bool operator== (const price &a, const price &b)
 
bool operator< (const price &a, const price &b)
 
asset operator* (const asset &a, const price &b)
 Multiply and round down. More...
 
price operator/ (const asset &base, const asset &quote)
 
price operator* (const price &p, const ratio_type &r)
 
price operator/ (const price &p, const ratio_type &r)
 
bool is_valid_symbol (const string &symbol)
 
void add_authority_accounts (flat_set< account_id_type > &result, const authority &a)
 
template object_restriction_predicate< share_typecreate_predicate_function (restriction_function func, restriction_argument arg)
 
result_type get_restriction_predicate_list_1 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_10 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_11 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_12 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_2 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_3 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_4 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_5 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_6 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_7 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_8 (size_t idx, vector< restriction > rs)
 
result_type get_restriction_predicate_list_9 (size_t idx, vector< restriction > rs)
 
restriction_predicate_function get_restriction_predicate (vector< restriction > rs, operation::tag_type op_type)
 get_restriction_predicate Get a predicate function for the supplied restriction More...
 
template<typename I , typename = std::enable_if_t<std::is_integral<I>::value>>
const auto & to_num (const I &i)
 
template<typename I >
const auto & to_num (const fc::safe< I > &i)
 
auto to_num (const fc::time_point_sec &t)
 
template<typename Object >
object_restriction_predicate< Object > restrictions_to_predicate (vector< restriction >, bool)
 
template<typename F , typename P , typename A , typename = std::enable_if_t<P::valid>>
object_restriction_predicate< F > embed_argument (P p, A a, short)
 
template<typename F , typename P , typename A >
object_restriction_predicate< F > embed_argument (P, A, long)
 
template<template< typename... > class Predicate, typename Field , typename ArgVariant >
object_restriction_predicate< Field > make_predicate (ArgVariant arg)
 
template<typename Object , typename = std::enable_if_t<typelist::length<typename fc::reflector<Object>::native_members>() != 0>>
object_restriction_predicate< Object > create_field_predicate (restriction &&r, short)
 Create a predicate asserting on the field of the object a restriction is referencing. More...
 
template<typename Object >
object_restriction_predicate< Object > create_field_predicate (restriction &&, long)
 
template<typename Object >
object_restriction_predicate< Object > create_logical_or_predicate (vector< vector< restriction >> rs)
 
bool operator== (const address &a, const address &b)
 
bool operator!= (const address &a, const address &b)
 
bool operator< (const address &a, const address &b)
 
price operator~ (const price &p)
 
bool operator> (const price &a, const price &b)
 
bool operator<= (const price &a, const price &b)
 
bool operator>= (const price &a, const price &b)
 
bool operator!= (const price &a, const price &b)
 
priceoperator*= (price &p, const ratio_type &r)
 
priceoperator/= (price &p, const ratio_type &r)
 
void operation_get_required_authorities (const operation &op, flat_set< account_id_type > &active, flat_set< account_id_type > &owner, vector< authority > &other, bool ignore_custom_operation_required_auths)
 
void operation_validate (const operation &op)
 
bool operator== (const pts_address &a, const pts_address &b)
 
bool operator!= (const pts_address &a, const pts_address &b)
 
bool operator< (const pts_address &a, const pts_address &b)
 
void validate_special_authority (const special_authority &auth)
 
void verify_authority (const vector< operation > &ops, const flat_set< public_key_type > &sigs, const std::function< const authority *(account_id_type)> &get_active, const std::function< const authority *(account_id_type)> &get_owner, const custom_authority_lookup &get_custom, bool allow_non_immediate_owner, bool ignore_custom_operation_required_auths, uint32_t max_recursion=GRAPHENE_MAX_SIG_CHECK_DEPTH, bool allow_committee=false, const flat_set< account_id_type > &active_aprovals=flat_set< account_id_type >(), const flat_set< account_id_type > &owner_approvals=flat_set< account_id_type >())
 
bool is_relative (object_id_type o)
 
 FC_IMPLEMENT_DERIVED_EXCEPTION (transaction_exception, protocol_exception, 4010000,"transaction validation exception") FC_IMPLEMENT_DERIVED_EXCEPTION(tx_missing_active_auth
 
missing required active authority FC_IMPLEMENT_DERIVED_EXCEPTION (tx_missing_owner_auth, transaction_exception, 4010002,"missing required owner authority") FC_IMPLEMENT_DERIVED_EXCEPTION(tx_missing_other_auth
 
missing required active authority missing required other authority FC_IMPLEMENT_DERIVED_EXCEPTION (tx_irrelevant_sig, transaction_exception, 4010004,"irrelevant signature included") FC_IMPLEMENT_DERIVED_EXCEPTION(tx_duplicate_sig
 
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)
 

Variables

const int64_t scaled_precision_lut [19]
 
 transaction_exception
 
const flat_set< public_key_typeempty_keyset
 

Typedef Documentation

Definition at line 38 of file asset_ops.hpp.

Definition at line 138 of file restriction_predicate.hxx.

Definition at line 242 of file types.hpp.

Definition at line 132 of file types.hpp.

Definition at line 243 of file types.hpp.

using graphene::protocol::comparable_types_list = typedef typelist::list<int64_t, string, time_point_sec, account_id_type, asset_id_type, force_settlement_id_type, committee_member_id_type, witness_id_type, limit_order_id_type, call_order_id_type, custom_id_type, proposal_id_type, withdraw_permission_id_type, vesting_balance_id_type, worker_id_type, balance_id_type>

Definition at line 128 of file restriction_predicate.hxx.

using graphene::protocol::custom_authority_lookup = typedef std::function<vector<authority>(account_id_type, const operation&, rejected_predicate_map*)>

Definition at line 33 of file transaction.hpp.

Definition at line 245 of file types.hpp.

Definition at line 136 of file restriction_predicate.hxx.

Definition at line 35 of file fee_schedule.hpp.

Definition at line 228 of file fee_schedule.hpp.

Definition at line 36 of file htlc.hpp.

Definition at line 33 of file htlc.hpp.

Definition at line 34 of file htlc.hpp.

Definition at line 35 of file htlc.hpp.

Definition at line 43 of file htlc.hpp.

Definition at line 133 of file restriction_predicate.hxx.

template<typename... >
using graphene::protocol::make_void = typedef void

Definition at line 39 of file restriction_predicate.hxx.

template<typename Field >
using graphene::protocol::object_restriction_predicate = typedef std::function<predicate_result(const Field&)>

Definition at line 69 of file restriction_predicate.hxx.

Definition at line 33 of file sliced_lists.hxx.

Definition at line 42 of file sliced_lists.hxx.

Definition at line 48 of file sliced_lists.hxx.

Definition at line 49 of file sliced_lists.hxx.

Definition at line 34 of file sliced_lists.hxx.

Definition at line 35 of file sliced_lists.hxx.

Definition at line 36 of file sliced_lists.hxx.

Definition at line 37 of file sliced_lists.hxx.

Definition at line 38 of file sliced_lists.hxx.

Definition at line 39 of file sliced_lists.hxx.

Definition at line 40 of file sliced_lists.hxx.

Definition at line 41 of file sliced_lists.hxx.

Definition at line 140 of file restriction_predicate.hxx.

When defining predicates do not make the protocol dependent upon implementation details.

Definition at line 83 of file assert.hpp.

Definition at line 131 of file types.hpp.

using graphene::protocol::ratio_type = typedef boost::rational<int32_t>

Definition at line 133 of file types.hpp.

Definition at line 30 of file transaction.hpp.

using graphene::protocol::rejected_predicate_map = typedef map<custom_authority_id_type, rejected_predicate>

Definition at line 31 of file transaction.hpp.

Definition at line 36 of file restriction_predicate.hxx.

Definition at line 35 of file restriction_predicate.hxx.

A restriction predicate is a function accepting an operation and returning a predicate_result.

Definition at line 62 of file restriction_predicate.hpp.

Definition at line 29 of file list_1.cpp.

using graphene::protocol::share_type = typedef safe<int64_t>

Definition at line 247 of file types.hpp.

Definition at line 246 of file types.hpp.

Definition at line 41 of file special_authority.hpp.

Definition at line 244 of file types.hpp.

Definition at line 54 of file vesting.hpp.

Definition at line 56 of file sliced_lists.hxx.

using graphene::protocol::weight_type = typedef uint16_t

Definition at line 248 of file types.hpp.

Enumeration Type Documentation

Enumerator
charge_market_fee 

market trades in this asset may be charged

Note
If one of these bits is set in asset issuer permissions, it means the asset issuer (or owner for bitassets) has the permission to update the corresponding flag, parameters or perform certain actions.
white_list 

accounts must be whitelisted in order to hold or transact this asset

override_authority 

issuer may transfer asset back to himself

transfer_restricted 

require the issuer to be one party to every transfer

disable_force_settle 

disable force settling

global_settle 

allow the bitasset owner to force a global settling, permission only

disable_confidential 

disallow the asset to be used with confidential transactions

witness_fed_asset 

the bitasset is to be fed by witnesses

committee_fed_asset 

the bitasset is to be fed by the committee

lock_max_supply 

the max supply of the asset can not be updated

Note
If one of these bits is set in asset issuer permissions, it means the asset issuer (or owner for bitassets) does NOT have the permission to update the corresponding flag, parameters or perform certain actions. This is to be compatible with old client software.
disable_new_supply 

unable to create new supply for the asset

disable_mcr_update 

the bitasset owner can not update MCR, permisison only

Note
These parameters are for issuer permission only. For each parameter, if it is set in issuer permission, it means the bitasset owner can not update the corresponding parameter. In this case, if the value of the parameter was set by the bitasset owner, it can not be updated; if no value was set by the owner, the value can still be updated by the feed producers.
disable_icr_update 

the bitasset owner can not update ICR, permisison only

disable_mssr_update 

the bitasset owner can not update MSSR, permisison only

Definition at line 135 of file types.hpp.

Enumerator
relative_protocol_ids 
protocol_ids 
implementation_ids 

Definition at line 234 of file types.hpp.

Type of a ticket.

Enumerator
liquid 
lock_180_days 
lock_360_days 
lock_720_days 
lock_forever 
TICKET_TYPE_COUNT 

Definition at line 33 of file ticket.hpp.

Function Documentation

void graphene::protocol::add_authority_accounts ( flat_set< account_id_type > &  result,
const authority a 
)

Add all account members of the given authority to the given flat_set.

Definition at line 31 of file authority.cpp.

template<typename Object , typename = std::enable_if_t<typelist::length<typename fc::reflector<Object>::native_members>() != 0>>
object_restriction_predicate<Object> graphene::protocol::create_field_predicate ( restriction &&  r,
short   
)

Create a predicate asserting on the field of the object a restriction is referencing.

Template Parameters
ObjectThe type the restriction restricts

A restriction specifies requirements about a field of an object. This struct shifts the focus from the object type the restriction references to the particular field type, creates a predicate on that field, and wraps that predicate to accept the object type and invoke the inner predicate on the specified field.

Definition at line 526 of file restriction_predicate.hxx.

template<typename Object >
object_restriction_predicate<Object> graphene::protocol::create_field_predicate ( restriction &&  ,
long   
)

Definition at line 540 of file restriction_predicate.hxx.

template<typename Object >
object_restriction_predicate<Object> graphene::protocol::create_logical_or_predicate ( vector< vector< restriction >>  rs)

Definition at line 546 of file restriction_predicate.hxx.

template object_restriction_predicate< extensions_type > graphene::protocol::create_predicate_function ( restriction_function  func,
restriction_argument  arg 
)

Definition at line 469 of file restriction_predicate.hxx.

template<typename F , typename P , typename A , typename = std::enable_if_t<P::valid>>
object_restriction_predicate<F> graphene::protocol::embed_argument ( p,
a,
short   
)

Definition at line 447 of file restriction_predicate.hxx.

template<typename F , typename P , typename A >
object_restriction_predicate<F> graphene::protocol::embed_argument ( ,
,
long   
)

Definition at line 454 of file restriction_predicate.hxx.

graphene::protocol::FC_IMPLEMENT_DERIVED_EXCEPTION ( transaction_exception  ,
protocol_exception  ,
4010000  ,
"transaction validation exception"   
)
missing required active authority graphene::protocol::FC_IMPLEMENT_DERIVED_EXCEPTION ( tx_missing_owner_auth  ,
transaction_exception  ,
4010002  ,
"missing required owner authority  
)
missing required active authority missing required other authority graphene::protocol::FC_IMPLEMENT_DERIVED_EXCEPTION ( tx_irrelevant_sig  ,
transaction_exception  ,
4010004  ,
"irrelevant signature included"   
)
restriction_predicate_function graphene::protocol::get_restriction_predicate ( vector< restriction rs,
operation::tag_type  op_type 
)

get_restriction_predicate Get a predicate function for the supplied restriction

Parameters
rsThe restrictions to evaluate operations against
op_typeThe tag specifying which operation type the restrictions apply to
Returns
A predicate function which evaluates an operation to determine whether it complies with the restriction

Definition at line 32 of file restriction_predicate.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_1 ( size_t  idx,
vector< restriction rs 
)

Definition at line 31 of file list_1.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_10 ( size_t  idx,
vector< restriction rs 
)

Definition at line 31 of file list_10.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_11 ( size_t  idx,
vector< restriction rs 
)

Definition at line 31 of file list_11.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_12 ( size_t  idx,
vector< restriction rs 
)

Definition at line 31 of file list_12.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_2 ( size_t  idx,
vector< restriction rs 
)

Definition at line 32 of file list_2.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_3 ( size_t  idx,
vector< restriction rs 
)

Definition at line 32 of file list_3.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_4 ( size_t  idx,
vector< restriction rs 
)

Definition at line 32 of file list_4.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_5 ( size_t  idx,
vector< restriction rs 
)

Definition at line 32 of file list_5.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_6 ( size_t  idx,
vector< restriction rs 
)

Definition at line 32 of file list_6.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_7 ( size_t  idx,
vector< restriction rs 
)

Definition at line 32 of file list_7.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_8 ( size_t  idx,
vector< restriction rs 
)

Definition at line 32 of file list_8.cpp.

object_restriction_predicate< operation > graphene::protocol::get_restriction_predicate_list_9 ( size_t  idx,
vector< restriction rs 
)

Definition at line 32 of file list_9.cpp.

bool graphene::protocol::is_cheap_name ( const string &  n)

Definition at line 129 of file account.cpp.

bool graphene::protocol::is_relative ( object_id_type  o)
inline

Definition at line 240 of file types.hpp.

bool graphene::protocol::is_valid_name ( const 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) GRAPHENE_MIN_ACCOUNT_NAME_LENGTH and GRAPHENE_MAX_ACCOUNT_NAME_LENGTH

Definition at line 60 of file account.cpp.

bool graphene::protocol::is_valid_symbol ( const string &  symbol)

Valid symbols can contain [A-Z0-9], and '.' They must start with [A, Z] They must end with [A, Z] before HF_620 or [A-Z0-9] after it They can contain a maximum of one '.'

Definition at line 38 of file asset_ops.cpp.

template<template< typename... > class Predicate, typename Field , typename ArgVariant >
object_restriction_predicate<Field> graphene::protocol::make_predicate ( ArgVariant  arg)

Definition at line 460 of file restriction_predicate.hxx.

void graphene::protocol::operation_get_required_authorities ( const operation op,
flat_set< account_id_type > &  active,
flat_set< account_id_type > &  owner,
vector< authority > &  other,
bool  ignore_custom_operation_required_auths 
)

Appends required authorites to the result vector. The authorities appended are not the same as those returned by get_required_auth

Returns
a set of required authorities for op

Definition at line 103 of file operations.cpp.

void graphene::protocol::operation_validate ( const operation op)

Definition at line 98 of file operations.cpp.

bool graphene::protocol::operator!= ( const pts_address a,
const pts_address b 
)
inline

Definition at line 56 of file pts_address.hpp.

bool graphene::protocol::operator!= ( const address a,
const address b 
)
inline

Definition at line 61 of file address.hpp.

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

Definition at line 86 of file types.cpp.

bool graphene::protocol::operator!= ( const price a,
const price b 
)
inline

Definition at line 148 of file asset.hpp.

asset graphene::protocol::operator* ( const asset a,
const price b 
)

Multiply and round down.

Definition at line 59 of file asset.cpp.

price graphene::protocol::operator* ( const price p,
const ratio_type r 
)

Definition at line 107 of file asset.cpp.

price& graphene::protocol::operator*= ( price p,
const ratio_type r 
)
inline

Definition at line 155 of file asset.hpp.

price graphene::protocol::operator/ ( const asset base,
const asset quote 
)

Definition at line 98 of file asset.cpp.

price graphene::protocol::operator/ ( const price p,
const ratio_type r 
)

Definition at line 189 of file asset.cpp.

price& graphene::protocol::operator/= ( price p,
const ratio_type r 
)
inline

Definition at line 157 of file asset.hpp.

bool graphene::protocol::operator< ( const price a,
const price b 
)

Definition at line 46 of file asset.cpp.

bool graphene::protocol::operator< ( const pts_address a,
const pts_address b 
)
inline

Definition at line 57 of file pts_address.hpp.

bool graphene::protocol::operator< ( const address a,
const address b 
)
inline

Definition at line 62 of file address.hpp.

bool graphene::protocol::operator<= ( const price a,
const price b 
)
inline

Definition at line 146 of file asset.hpp.

bool graphene::protocol::operator== ( const price a,
const price b 
)

Definition at line 35 of file asset.cpp.

bool graphene::protocol::operator== ( const pts_address a,
const pts_address b 
)
inline

Definition at line 55 of file pts_address.hpp.

bool graphene::protocol::operator== ( const address a,
const address b 
)
inline

Definition at line 60 of file address.hpp.

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

Definition at line 76 of file types.cpp.

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

Definition at line 81 of file types.cpp.

bool graphene::protocol::operator> ( const price a,
const price b 
)
inline

Definition at line 145 of file asset.hpp.

bool graphene::protocol::operator>= ( const price a,
const price b 
)
inline

Definition at line 147 of file asset.hpp.

price graphene::protocol::operator~ ( const price p)
inline

Definition at line 140 of file asset.hpp.

template<typename Object >
object_restriction_predicate< Object > graphene::protocol::restrictions_to_predicate ( vector< restriction rs,
bool  allow_empty 
)

Definition at line 568 of file restriction_predicate.hxx.

template<typename I , typename = std::enable_if_t<std::is_integral<I>::value>>
const auto& graphene::protocol::to_num ( const I &  i)

Definition at line 73 of file restriction_predicate.hxx.

template<typename I >
const auto& graphene::protocol::to_num ( const fc::safe< I > &  i)

Definition at line 75 of file restriction_predicate.hxx.

auto graphene::protocol::to_num ( const fc::time_point_sec t)
inline

Definition at line 76 of file restriction_predicate.hxx.

void graphene::protocol::validate_special_authority ( const special_authority auth)

Definition at line 43 of file special_authority.cpp.

Variable Documentation

const flat_set<public_key_type> graphene::protocol::empty_keyset

Definition at line 115 of file transaction.cpp.

const int64_t graphene::protocol::scaled_precision_lut
Initial value:
=
{
p10< 0 >::v, p10< 1 >::v, p10< 2 >::v, p10< 3 >::v,
p10< 4 >::v, p10< 5 >::v, p10< 6 >::v, p10< 7 >::v,
p10< 8 >::v, p10< 9 >::v, p10< 10 >::v, p10< 11 >::v,
p10< 12 >::v, p10< 13 >::v, p10< 14 >::v, p10< 15 >::v,
p10< 16 >::v, p10< 17 >::v, p10< 18 >::v
}

Definition at line 342 of file asset.cpp.

missing required active authority missing required other authority graphene::protocol::transaction_exception

Definition at line 40 of file small_ops.cpp.