8

Declare the following struct in your contract struct account { asset balance; uint64_t primary_key()const { return balance.symbol.name(); } }; typedef eosio::multi_index<N(accounts), account> accounts; Write the following in one of the action of contract. It is reading the accounts table of eosio.token contract and printing ...


4

Your EOS balance is tokens that you can transfer at this moment, but 'Mortgage' actually means 'Staked'. These are reserved and you cannot transfer them until they are released. Your will be able to unstake your tokens when the voting reaches %15 I believe 'Mortgage' will be used when you rent out your tokens for dApp developers for bandwidth when the ...


2

According to the responses in this GitHub issue, the mechanisms that are meant to mitigate this issue are as follows: There's a maximum cpu time(30ms) for every transaction. If a transaction failed, it will not be broadcast to other nodes, which means that hackers can only exhausts one see node rather than the whole network. greylist feature ...


2

There is nothing like addresses on EOS. Only Accountnames and key-pairs. There's no endpoint for querying by public Key. Key-pairs can be used for multiple Accounts - so you can't query the Balance of a single account by public Key.


1

You can specify the core symbol when building. In the main chain's case, EOS is the core symbol. The flag to pass is -s [CORE_SYMBOL]. You can see this in the Build.sh file. [CoreSymbolName -s <1-7 characters>] You can also see the logic for defaulting as SYS in the Build.sh CORE_SYMBOL_NAME="SYS" To create the SYS token, you first need to ...


1

@Max your approach is good, but I think you can make it cleaner by using the token symbol directly doing something similar to what I did here: https://github.com/andresberrios/token_ram_recovery/blob/master/token_ram_recovery.cpp#L9 Specifically, getting the parameter as a string type and then converting it to a symbol_type: symbol_type sym = ...


1

EOS is an account based system. https://github.com/EOSIO/eos/wiki/Accounts-&-Permissions Furthermore EOS differentiates from Ethereum that an account has an upfront setup cost. In Ethereum an account is basically your public private key pair. In EOS you need to allocate the account for yourself. How will someone new to EOS create an EOS account today


1

In the current implementation of EOSIO software, the account balances can not be made confidential. Each user's balance is stored in a table alongside their username. In addition to this, any transaction performed by a user would show the from and to fields, so that you could follow who sent tokens to another account. Workaround A semi-workaround to this ...


Only top voted, non community-wiki answers of a minimum length are eligible