observer

package
v0.0.0-...-c0f8dde Latest Latest
Warning

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

Go to latest
Published: Aug 21, 2020 License: GPL-3.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BtcObConfig

type BtcObConfig struct {
	NetType            string `json:"net_type"`
	BtcObLoopWaitTime  int64  `json:"btc_ob_loop_wait_time"`
	BtcObConfirmations uint32 `json:"btc_ob_confirmations"`
	BtcJsonRpcAddress  string `json:"btc_json_rpc_address"`
	User               string `json:"user"`
	Pwd                string `json:"pwd"`
	StartHeight        uint32 `json:"start_height"`
}

type BtcObserver

type BtcObserver struct {
	NetParam *chaincfg.Params
	// contains filtered or unexported fields
}

func NewBtcObserver

func NewBtcObserver(conf *BtcObConfig, cli *utils.RestCli, poly *sdk.PolySdk) *BtcObserver

func (*BtcObserver) Listen

func (observer *BtcObserver) Listen(cc chan *utils.CrossChainItem, hc chan *utils.Header)

func (*BtcObserver) SearchTxInBlock

func (observer *BtcObserver) SearchTxInBlock(txns []*wire.MsgTx, height uint32, relaying chan *utils.CrossChainItem) int

type Checkpoint

type Checkpoint struct {
	Height uint32
}

type PolyObConfig

type PolyObConfig struct {
	PolyObLoopWaitTime int64  `json:"poly_ob_loop_wait_time"`
	WatchingKey        string `json:"watching_key"`
	PolyJsonRpcAddress string `json:"poly_json_rpc_address"`
	WalletFile         string `json:"wallet_file"`
	WalletPwd          string `json:"wallet_pwd"`
	NetType            string `json:"net_type"`
	WaitingCycle       uint32 `json:"waiting_cycle"`
}

type PolyObserver

type PolyObserver struct {
	// contains filtered or unexported fields
}

func NewPolyObserver

func NewPolyObserver(poly *sdk.PolySdk, conf *PolyObConfig, rdb *db.RetryDB) *PolyObserver

func (*PolyObserver) Listen

func (observer *PolyObserver) Listen(collecting chan *utils.FromPolyItem)

type Record

type Record struct {
	// contains filtered or unexported fields
}

func (*Record) String

func (r *Record) String() string

Jump to

Keyboard shortcuts

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