Documentation ¶
Index ¶
- Constants
- func InitZip(db StateDB, total *big.Int, decimals uint64) error
- type Account
- type AccountAssetInfo
- type Asset
- func (a *Asset) AddBalance(targetAddr common.Address, assetAddr common.Address, value interface{}) error
- func (a *Asset) CreateAccount(addr common.Address) error
- func (a *Asset) Empty(targetAddr common.Address) bool
- func (a *Asset) EnoughBalance(targetAddr common.Address, assetAddr common.Address, value interface{}) (bool, error)
- func (a *Asset) Exist(targetAddr common.Address) bool
- func (a *Asset) GetBalance(targetAddr common.Address, assetAddr common.Address) interface{}
- func (a *Asset) GetNonce(targetAddr common.Address) uint64
- func (a *Asset) GetUserAssets(address common.Address) ([]UserAsset, error)
- func (a *Asset) IssueAsset(ownerAddr common.Address, assetAddr common.Address, value interface{}) error
- func (a *Asset) RegisterAsset(baseType int, accountAddr common.Address, desc string) (common.Address, error)
- func (a *Asset) SetNewOwner(oldOwner common.Address, assetAddr common.Address, newOwner common.Address) (bool, error)
- func (a *Asset) SetNonce(targetAddr common.Address, nonce uint64) error
- func (a *Asset) SubBalance(targetAddr common.Address, assetAddr common.Address, value interface{}) error
- type StateDB
- type UserAsset
Constants ¶
View Source
const ( // AccountModel account AccountModel = iota // UtxoModel account UtxoModel )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type AccountAssetInfo ¶
type AccountAssetInfo struct { Name string Symbol string Total *big.Int Decimals uint64 Owner common.Address }
AccountAssetInfo .
type Asset ¶
type Asset struct {
// contains filtered or unexported fields
}
Asset operating user assets
func (*Asset) AddBalance ¶
func (a *Asset) AddBalance(targetAddr common.Address, assetAddr common.Address, value interface{}) error
AddBalance add account balance
func (*Asset) CreateAccount ¶
CreateAccount create account
func (*Asset) EnoughBalance ¶
func (a *Asset) EnoughBalance(targetAddr common.Address, assetAddr common.Address, value interface{}) (bool, error)
EnoughBalance .
func (*Asset) GetBalance ¶
GetBalance get account balance
func (*Asset) GetUserAssets ¶
GetUserAssets .
func (*Asset) IssueAsset ¶
func (a *Asset) IssueAsset(ownerAddr common.Address, assetAddr common.Address, value interface{}) error
IssueAsset issue asset
func (*Asset) RegisterAsset ¶
func (a *Asset) RegisterAsset(baseType int, accountAddr common.Address, desc string) (common.Address, error)
RegisterAsset create asset
func (*Asset) SetNewOwner ¶
func (a *Asset) SetNewOwner(oldOwner common.Address, assetAddr common.Address, newOwner common.Address) (bool, error)
SetNewOwner .
Click to show internal directories.
Click to hide internal directories.