flight

package
v0.0.0-...-93382e6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 10, 2022 License: GPL-3.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var SRI_Inst = SRI{}

Functions

func ConfirmOutC

func ConfirmOutC(key *c_type.Uint256, c *tx.Out_C) (dout txtool.TDOut, e error)

func CurrencyToId

func CurrencyToId(currency string) (ret c_type.Uint256)

func DecOut

func DecOut(tk *c_type.Tk, outs []txtool.Out) (douts []txtool.TDOut)

func GenTx

func GenTx(param *txtool.GTxParam) (gtx txtool.GTx, e error)

func GenTxParam

func GenTxParam(param *PreTxParam, tk c_type.Tk) (p txtool.GTxParam, e error)

func GetBlock

func GetBlock(num uint64, hash *common.Hash) (ret *localdb.Block)

func GetOut

func GetOut(root *c_type.Uint256, num uint64) (out *localdb.RootState)

func IdToCurrency

func IdToCurrency(id *c_type.Uint256) (ret string)

func ProveTx1

func ProveTx1(tx *stx.T, param *txtool.GTxParam) (gtx txtool.GTx, e error)

func SignLight

func SignLight(sk *c_type.Uint512, paramTx *txtool.GTxParam) (tx stx.T, param txtool.GTxParam, keys []c_type.Uint256, bases []c_type.Uint256, e error)

func SignTx

func SignTx(sk *c_type.Uint512, paramTx *txtool.GTxParam) (tx txtool.GTx, e error)

func SignTx0

func SignTx0(param *txtool.GTxParam) (gtx txtool.GTx, e error)

func SignTx1

func SignTx1(txParam *txtool.GTxParam) (tx stx.T, param txtool.GTxParam, keys []c_type.Uint256, bases []c_type.Uint256, e error)

func Trace2Root

func Trace2Root(tk *c_type.Tk, trace *c_type.Uint256, base *c_type.Uint256) (root *c_type.Uint256)

Types

type PreTxParam

type PreTxParam struct {
	Gas      uint64
	GasPrice uint64
	From     c_type.PKr
	Ins      []c_type.Uint256
	Outs     []txtool.GOut
}

type SRI

type SRI struct {
}

func (*SRI) GetAnchor

func (self *SRI) GetAnchor(roots []c_type.Uint256) (wits []txtool.Witness, e error)

func (*SRI) GetBlocksInfo

func (self *SRI) GetBlocksInfo(start uint64, count uint64) (blocks []txtool.Block, e error)

func (*SRI) GetBlocksInfoByDelay

func (self *SRI) GetBlocksInfoByDelay(start uint64, count uint64, delay uint64) (blocks []txtool.Block, e error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL