Разработчикам Статистика Баунти Документация Партнеры Github
Public Member Functions | Public Attributes | List of all members
golos::chain::account_statistics_object Class Reference

#include <account_object.hpp>

Inheritance diagram for golos::chain::account_statistics_object:

Public Member Functions

 account_statistics_object ()=delete
template<typename Constructor , typename Allocator >
 account_statistics_object (Constructor &&c, allocator< Allocator > a)
void pay_fee (share_type core_fee, share_type cashback_vesting_threshold)

Public Attributes

id_type id
account_name_type owner
account_transaction_history_object::id_type most_recent_op
uint32_t total_ops = 0
uint32_t removed_ops = 0
share_type total_core_in_orders
share_type lifetime_fees_paid
share_type pending_fees
share_type pending_vested_fees

Detailed Description

This object contains regularly updated statistical data about an account. It is provided for the purpose of separating the account data that changes frequently from the account data that is mostly static, which will minimize the amount of data that must be backed up as part of the undo history everytime a transfer is made.

Definition at line 31 of file account_object.hpp.

Constructor & Destructor Documentation

◆ account_statistics_object() [1/2]

golos::chain::account_statistics_object::account_statistics_object ( )

◆ account_statistics_object() [2/2]

template<typename Constructor , typename Allocator >
golos::chain::account_statistics_object::account_statistics_object ( Constructor &&  c,
allocator< Allocator >  a 

Definition at line 37 of file account_object.hpp.

Member Function Documentation

◆ pay_fee()

void golos::chain::account_statistics_object::pay_fee ( share_type  core_fee,
share_type  cashback_vesting_threshold 

Core fees are paid into the account_statistics_object by this method

Definition at line 26 of file account_object.cpp.

Member Data Documentation

◆ id

id_type golos::chain::account_statistics_object::id

Definition at line 39 of file account_object.hpp.

◆ lifetime_fees_paid

share_type golos::chain::account_statistics_object::lifetime_fees_paid

Tracks the total fees paid by this account for the purpose of calculating bulk discounts.

Definition at line 64 of file account_object.hpp.

◆ most_recent_op

account_transaction_history_object::id_type golos::chain::account_statistics_object::most_recent_op

Keep the most recent operation as a root pointer to a linked list of the transaction history.

Definition at line 48 of file account_object.hpp.

◆ owner

account_name_type golos::chain::account_statistics_object::owner

Definition at line 43 of file account_object.hpp.

◆ pending_fees

share_type golos::chain::account_statistics_object::pending_fees

Tracks the fees paid by this account which have not been disseminated to the various parties that receive them yet (registrar, referrer, lifetime referrer, network, etc). This is used as an optimization to avoid doing massive amounts of uint128 arithmetic on each and every operation.

These fees will be paid out as vesting cash-back, and this counter will reset during the maintenance interval.

Definition at line 74 of file account_object.hpp.

◆ pending_vested_fees

share_type golos::chain::account_statistics_object::pending_vested_fees

Same as pending_fees, except these fees will be paid out as pre-vested cash-back (immediately available for withdrawal) rather than requiring the normal vesting period.

Definition at line 79 of file account_object.hpp.

◆ removed_ops

uint32_t golos::chain::account_statistics_object::removed_ops = 0

Total operations related to this account that has been removed from the database.

Definition at line 52 of file account_object.hpp.

◆ total_core_in_orders

share_type golos::chain::account_statistics_object::total_core_in_orders

When calculating votes it is necessary to know how much is stored in orders (and thus unavailable for transfers). Rather than maintaining an index of [asset,owner,order_id] we will simply maintain the running total here and update it every time an order is created or modified.

Definition at line 59 of file account_object.hpp.

◆ total_ops

uint32_t golos::chain::account_statistics_object::total_ops = 0

Total operations related to this account.

Definition at line 50 of file account_object.hpp.

The documentation for this class was generated from the following files: