Documentation
¶
Index ¶
- Constants
- func AddExecAddress(address string)
- func Init(title string, addresses []string)
- func InitDB(cli db.DBCreator) error
- func NewAccountKey(id string) *db.IKey
- func NewAccountRecordKey(id string) *db.IKey
- func RecordHelper(log *types.ReceiptLog, op int, acc Account) ([]db.Record, error)
- type Account
- type Detall
- func AssetLogConvert(ty int32, v []byte, op int) (*Detall, error)
- func LogBurnConvert(v []byte, op int) (*Detall, error)
- func LogDepositConvert(v []byte, op int) (*Detall, error)
- func LogExecActiveConvert(v []byte, op int) (*Detall, error)
- func LogExecDepositConvert(v []byte, op int) (*Detall, error)
- func LogExecFrozenConvert(v []byte, op int) (*Detall, error)
- func LogExecTransferConvert(v []byte, op int) (*Detall, error)
- func LogExecWithdrawConvert(v []byte, op int) (*Detall, error)
- func LogFeeConvert(v []byte, op int) (*Detall, error)
- func LogGenesisDepositConvert(v []byte, op int) (*Detall, error)
- func LogGenesisTransferConvert(v []byte, op int) (*Detall, error)
- func LogMintConvert(v []byte, op int) (*Detall, error)
- func LogTransferConvert(v []byte, op int) (*Detall, error)
- type Record
Constants ¶
const ( AccountPersonage = "personage" AccountContract = "contract" AccountContractInternal = "contractInternal" )
account ypte
const ( DBX = "account" TableX = "account" RAccountX = "account" AccountRecordDBX = "account_record" AccountRecordTableX = "account_record" DefaultType = "_doc" )
default asset db
const ( ExecCoinsX = "coins" ExecCoinsxX = "coinsx" )
asset
const AccountMapping = `` /* 912-byte string literal not displayed */
AccountMapping mapping
Variables ¶
This section is empty.
Functions ¶
func NewAccountRecordKey ¶
NewAccountRecordKey New AccountRecordKey
func RecordHelper ¶
RecordHelper create account record
Types ¶
type Account ¶
type Account struct {
*Detall
HeightIndex int64 `json:"height_index"`
AssetSymbol string `json:"asset_symbol"`
AssetExec string `json:"asset_exec"`
Height int64 `json:"height"`
BlockTime int64 `json:"block_time"`
}
Account 记录帐号信息, Detail 解析自执行日志, 其他项在交易解析时获得
type Detall ¶
type Detall struct {
Address string `json:"address"`
Exec string `json:"exec"` // 执行器名 和 执行器地址 等效, 可能不知道执行器名, 这时填地址
Frozen int64 `json:"frozen"`
Balance int64 `json:"balance"`
Total int64 `json:"total"`
Type string `json:"type"` // contract, personage
AddrType string `json:"addr_type"`
}
Detall id: address-exec-asset
func AssetLogConvert ¶
AssetLogConvert convert asset log
func LogBurnConvert ¶
LogBurnConvert LogBurnConvert
func LogDepositConvert ¶
LogDepositConvert LogDepositConvert
func LogExecActiveConvert ¶
LogExecActiveConvert LogExecActiveConvert
func LogExecDepositConvert ¶
LogExecDepositConvert LogExecDepositConvert
func LogExecFrozenConvert ¶
LogExecFrozenConvert LogExecFrozenConvert
func LogExecTransferConvert ¶
LogExecTransferConvert LogExecTransferConvert
func LogExecWithdrawConvert ¶
LogExecWithdrawConvert LogExecWithdrawConvert
func LogFeeConvert ¶
LogFeeConvert LogFeeConvert
func LogGenesisDepositConvert ¶
LogGenesisDepositConvert LogGenesisDepositConvert
func LogGenesisTransferConvert ¶
LogGenesisTransferConvert LogGenesisTransferConvert
func LogMintConvert ¶
LogMintConvert LogMintConvert